@@ -562,16 +562,8 @@ if _exists xargs && [ "$(printf %s '\\x41' | xargs printf)" = 'A' ]; then
...
@@ -562,16 +562,8 @@ if _exists xargs && [ "$(printf %s '\\x41' | xargs printf)" = 'A' ]; then
fi
fi
_h2b() {
_h2b() {
if _exists xxd; then
if _exists xxd && xxd -r -p 2>/dev/null; then
if _contains "$(xxd --help 2>&1)" "assumes -c30"; then
return
if xxd -r -p -c 9999 2>/dev/null; then
return
fi
else
if xxd -r -p 2>/dev/null; then
return
fi
fi
fi
fi
hex=$(cat)
hex=$(cat)
...
@@ -1132,7 +1124,7 @@ _createkey() {
...
@@ -1132,7 +1124,7 @@ _createkey() {
if _isEccKey "$length"; then
if _isEccKey "$length"; then
_debug "Using ec name: $eccname"
_debug "Using ec name: $eccname"
if _opkey="$(${ACME_OPENSSL_BIN:-openssl} ecparam -name "$eccname" -noout -genkey 2>/dev/null)"; then
if _opkey="$(${ACME_OPENSSL_BIN:-openssl} ecparam -name "$eccname" -genkey 2>/dev/null)"; then
echo "$_opkey" >"$f"
echo "$_opkey" >"$f"
else
else
_err "error ecc key name: $eccname"
_err "error ecc key name: $eccname"
...
@@ -1140,11 +1132,7 @@ _createkey() {
...
@@ -1140,11 +1132,7 @@ _createkey() {
fi
fi
else
else
_debug "Using RSA: $length"
_debug "Using RSA: $length"
__traditional=""
if _opkey="$(${ACME_OPENSSL_BIN:-openssl} genrsa "$length" 2>/dev/null)"; then
if _contains "$(${ACME_OPENSSL_BIN:-openssl} help genrsa 2>&1)" "-traditional"; then
__traditional="-traditional"
fi
if _opkey="$(${ACME_OPENSSL_BIN:-openssl} genrsa $__traditional "$length" 2>/dev/null)"; then
echo "$_opkey" >"$f"
echo "$_opkey" >"$f"
else
else
_err "error rsa key: $length"
_err "error rsa key: $length"
...
@@ -2133,12 +2121,6 @@ _send_signed_request() {
...
@@ -2133,12 +2121,6 @@ _send_signed_request() {
_sleep $_sleep_retry_sec
_sleep $_sleep_retry_sec
continue
continue
fi
fi
if _contains "$_body" "The Replay Nonce is not recognized"; then
_info "The replay Nonce is not valid, let's get a new one, Sleeping $_sleep_retry_sec seconds."
_CACHED_NONCE=""
_sleep $_sleep_retry_sec
continue
fi
fi
fi
return 0
return 0
done
done
...
@@ -2297,13 +2279,6 @@ _clearaccountconf() {
...
@@ -2297,13 +2279,6 @@ _clearaccountconf() {
_clear_conf "$ACCOUNT_CONF_PATH" "$1"
_clear_conf "$ACCOUNT_CONF_PATH" "$1"
}
}
#key
_clearaccountconf_mutable() {
_clearaccountconf "SAVED_$1"
#remove later
_clearaccountconf "$1"
}
#_savecaconf key value
#_savecaconf key value
_savecaconf() {
_savecaconf() {
_save_conf "$CA_CONF" "$1" "$2"
_save_conf "$CA_CONF" "$1" "$2"
...
@@ -4034,42 +4009,12 @@ _check_dns_entries() {
...
@@ -4034,42 +4009,12 @@ _check_dns_entries() {
}
}
#file
#file
_get_chain_issuers() {
_get_cert_issuers() {
_cfile="$1"
_cfile="$1"
if _contains "$(${ACME_OPENSSL_BIN:-openssl} help crl2pkcs7 2>&1)" "Usage: crl2pkcs7" || _contains "$(${ACME_OPENSSL_BIN:-openssl} crl2pkcs7 -help 2>&1)" "Usage: crl2pkcs7" || _contains "$(${ACME_OPENSSL_BIN:-openssl} crl2pkcs7 help 2>&1)" "unknown option help"; then
if _contains "$(${ACME_OPENSSL_BIN:-openssl} help crl2pkcs7 2>&1)" "Usage: crl2pkcs7" || _contains "$(${ACME_OPENSSL_BIN:-openssl} crl2pkcs7 help 2>&1)" "unknown option help"; then
if! _rest POST "Record.Create""login_token=$DP_Id,$DP_Key&format=json&lang=en&domain_id=$_domain_id&sub_domain=$_sub_domain&record_type=TXT&value=$txtvalue&record_line=%E9%BB%98%E8%AE%A4";then
if! _rest POST "Record.Create""login_token=$DP_Id,$DP_Key&format=json&lang=en&domain_id=$_domain_id&sub_domain=$_sub_domain&record_type=TXT&value=$txtvalue&record_line=默认";then