Comparing version 1.5.2 to 1.5.3
12
node.js
@@ -151,2 +151,3 @@ // Copyright 2018 AJ ONeal. All rights reserved | ||
if (options.externalAccount) { | ||
// TODO is this really done by HMAC or is it arbitrary? | ||
body.externalAccountBinding = me.RSA.signJws( | ||
@@ -641,2 +642,9 @@ options.externalAccount.secret | ||
}); | ||
}).sort(function (aType, bType) { | ||
var a = results.challenges.filter(function (ch) { return ch.type === aType; })[0]; | ||
var b = results.challenges.filter(function (ch) { return ch.type === bType; })[0]; | ||
if ('valid' === a.status) { return 1; } | ||
if ('valid' === b.status) { return -1; } | ||
return 0; | ||
})[0]; | ||
@@ -656,2 +664,6 @@ | ||
if ("valid" === challenge.status) { | ||
return; | ||
} | ||
return ACME._postChallenge(me, options, results.identifier, challenge); | ||
@@ -658,0 +670,0 @@ }).then(function () { |
{ | ||
"name": "acme-v2", | ||
"version": "1.5.2", | ||
"version": "1.5.3", | ||
"description": "Free SSL. A framework for building Let's Encrypt v2 clients, and other ACME v2 (draft 11) clients. Successor to le-acme-core.js", | ||
@@ -5,0 +5,0 @@ "homepage": "https://git.coolaj86.com/coolaj86/acme-v2.js", |
71359
1165