mirror of
https://github.com/acmesh-official/acme.sh.git
synced 2025-06-15 19:04:12 +00:00
haproxy: don't leak private keys when doing --debug
It was reported in issue #6267 that the private key was leaked when using the DEPLOY_HAPROXY_HOT_UPDATE=yes feature. Indeed, the debugging code which sends commands to HAProxy was using _debug even when passing the private key. This patch fixes the issue by using _secure_debug when doing that.
This commit is contained in:
parent
45660902ed
commit
7e320d2748
@ -357,7 +357,7 @@ haproxy_deploy() {
|
|||||||
_info "Update existing certificate '${_pem}' over HAProxy ${_socketname}."
|
_info "Update existing certificate '${_pem}' over HAProxy ${_socketname}."
|
||||||
fi
|
fi
|
||||||
_socat_cert_set_cmd="echo -e '${_cmdpfx}set ssl cert ${_pem} <<\n$(cat "${_pem}")\n' | socat '${_statssock}' - | grep -q 'Transaction created'"
|
_socat_cert_set_cmd="echo -e '${_cmdpfx}set ssl cert ${_pem} <<\n$(cat "${_pem}")\n' | socat '${_statssock}' - | grep -q 'Transaction created'"
|
||||||
_debug _socat_cert_set_cmd "${_socat_cert_set_cmd}"
|
_secure_debug _socat_cert_set_cmd "${_socat_cert_set_cmd}"
|
||||||
eval "${_socat_cert_set_cmd}"
|
eval "${_socat_cert_set_cmd}"
|
||||||
_ret=$?
|
_ret=$?
|
||||||
if [ "${_ret}" != "0" ]; then
|
if [ "${_ret}" != "0" ]; then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user