From 7e52ba31eff7d65a3f6d08c7fa7653861faefc50 Mon Sep 17 00:00:00 2001 From: raven-kg Date: Wed, 22 May 2019 09:38:02 +0600 Subject: [PATCH] Use _hmac and _base64 functions instead of openssl and base64 binaries --- notify/ses.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/notify/ses.sh b/notify/ses.sh index 692df24c..db290e72 100644 --- a/notify/ses.sh +++ b/notify/ses.sh @@ -58,7 +58,7 @@ ses_send() { _saveaccountconf_mutable AWS_SES_FROM "$AWS_SES_FROM" _date="$(date -R)" - _signature="$(echo -n "$_date" | ${ACME_OPENSSL_BIN:-openssl} dgst -sha256 -hmac "$AWS_SECRET_KEY" -binary | base64 -w 0)" + _signature="$(printf "%s" "$_date" | _hmac sha256 $AWS_SECRET_KEY | _base64)" _endpoint="https://email.$AWS_REGION.amazonaws.com" export _H1="X-Amzn-Authorization: AWS3-HTTPS AWSAccessKeyId=$AWS_ACCESS_KEY, Algorithm=HmacSHA256, Signature=$_signature"