From: Lukas Schauer Date: Mon, 14 Dec 2015 13:10:54 +0000 (+0100) Subject: fixed usage of openssl sha in newer openssl versions by using direct binary output X-Git-Tag: v0.1.0~132 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6816216fdbd5fa2e279f9385f3675b81d4334239;p=thirdparty%2Fdehydrated.git fixed usage of openssl sha in newer openssl versions by using direct binary output --- diff --git a/letsencrypt.sh b/letsencrypt.sh index aa64cd0..45d728f 100755 --- a/letsencrypt.sh +++ b/letsencrypt.sh @@ -132,7 +132,7 @@ init_system() { pubExponent64="$(printf "%06x" "$(openssl rsa -in "${PRIVATE_KEY}" -noout -text | grep publicExponent | head -1 | cut -d' ' -f2)" | hex2bin | urlbase64)" pubMod64="$(printf '%s' "$(openssl rsa -in "${PRIVATE_KEY}" -noout -modulus | cut -d'=' -f2)" | hex2bin | urlbase64)" - thumbprint="$(printf '%s' "$(printf '%s' '{"e":"'"${pubExponent64}"'","kty":"RSA","n":"'"${pubMod64}"'"}' | openssl sha -sha256)" | hex2bin | urlbase64)" + thumbprint="$(printf '%s' '{"e":"'"${pubExponent64}"'","kty":"RSA","n":"'"${pubMod64}"'"}' | openssl sha -sha256 -binary | urlbase64)" # If we generated a new private key in the step above we have to register it with the acme-server if [[ "${register}" = "1" ]]; then