diff --git a/lib/acme-client.js b/lib/acme-client.js index b5755d5..cb9a320 100644 --- a/lib/acme-client.js +++ b/lib/acme-client.js @@ -13,8 +13,8 @@ module.exports.create = function (deps) { var request=require('request'); var generateSignature=deps.RSA.signJws; - function Acme(privateKey) { - this.privateKey=privateKey; + function Acme(keypair) { + this.keypair; this.nonces=[]; } @@ -54,7 +54,7 @@ module.exports.create = function (deps) { log('Using nonce: '+this.nonces[0]); payload=JSON.stringify(body, null, 2); jws=generateSignature( - this.privateKey, new Buffer(payload), this.nonces.shift() + this.keypair, new Buffer(payload), this.nonces.shift() ); signed=JSON.stringify(jws, null, 2);