make alpn-validation certificates and keys group readable (closes #754, fixes #753)

This commit is contained in:
Georg Altmann
2020-08-15 14:53:04 +02:00
committed by Lukas Schauer
parent 829aaeff2d
commit 835963fa6e

View File

@@ -1279,6 +1279,7 @@ generate_alpn_certificate() {
SUBJ="/CN=${altname}/"
[[ "${OSTYPE:0:5}" = "MINGW" ]] && SUBJ="/${SUBJ}"
_openssl req -x509 -new -sha256 -nodes -newkey rsa:2048 -keyout "${alpncertdir}/${altname}.key.pem" -out "${alpncertdir}/${altname}.crt.pem" -subj "${SUBJ}" -extensions SAN -config "${tmp_openssl_cnf}"
chmod g+r "${alpncertdir}/${altname}.key.pem" "${alpncertdir}/${altname}.crt.pem"
rm -f "${tmp_openssl_cnf}"
}