ACME registration fix

This commit is contained in:
cry0this 2019-09-26 12:52:39 +03:00
commit 06a8f7d88a

View file

@ -103,7 +103,7 @@ fi
# Requesting ACME nonce
nonce=$(curl -s -I "$API/directory" |grep -i nonce |cut -f2 -d\ |tr -d '\r\n')
nonce=$(curl -s -I "$API/acme/new-nonce" |grep -i nonce |cut -f2 -d\ |tr -d '\r\n')
# Creating ACME account
url="$API/acme/new-acct"
@ -113,7 +113,7 @@ kid=$(echo "$answer" |grep -i location: |cut -f2 -d ' '|tr -d '\r')
# Checking answer status
status=$(echo "$answer" |grep HTTP/ |tail -n1 |cut -f2 -d ' ')
if [[ "${status:0:2}" -ne "20" ]]; then
if [[ "${status:0:2}" -ne "valid" ]]; then
check_result $E_CONNECT "Let's Encrypt acc registration failed $status"
fi