]> git.proxmox.com Git - mirror_acme.sh.git/commitdiff
fix #2830 Autorization segment typo fixed
authorOliver Burgmaier <oliver.burgmaier@daimler.com>
Wed, 1 Apr 2020 18:31:06 +0000 (20:31 +0200)
committerOliver Burgmaier <oliver.burgmaier@daimler.com>
Wed, 1 Apr 2020 18:31:06 +0000 (20:31 +0200)
This fixes the parsing of the authorization segment in the response of
an order. Without this fix the start of the array is not found
correctly and therefore the finalize URL is part of the authorization
segment. Changing the regex to *\[[^\[]*\] fix this. Seems to be a typo
which has not been recognized so far. This can be only recognized if
the response is in a single line.

acme.sh

diff --git a/acme.sh b/acme.sh
index 937e435c4d4c7acf517e92e4d0c96f94e67ea974..adf0342755c7f61b84bcc6e98ccdf4256d815b37 100755 (executable)
--- a/acme.sh
+++ b/acme.sh
@@ -4019,7 +4019,7 @@ issue() {
       #for dns manual mode
       _savedomainconf "Le_OrderFinalize" "$Le_OrderFinalize"
 
-      _authorizations_seg="$(echo "$response" | _egrep_o '"authorizations" *: *\[[^\[]]*\]' | cut -d '[' -f 2 | tr -d ']' | tr -d '"')"
+      _authorizations_seg="$(echo "$response" | _egrep_o '"authorizations" *: *\[[^\[]*\]' | cut -d '[' -f 2 | tr -d ']' | tr -d '"')"
       _debug2 _authorizations_seg "$_authorizations_seg"
       if [ -z "$_authorizations_seg" ]; then
         _err "_authorizations_seg not found."