summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2017-02-17 14:21:47 +0100
committerFelix Fietkau <nbd@nbd.name>2017-02-17 14:43:11 +0100
commitc835c9ebe59d071485ae61df021380a980f20976 (patch)
tree5bd0041d5a335edbab70e2bd1c513fd51fcd73cd
parent6ebb8723a69ca418ad78eea51258ab8bad0e3c70 (diff)
downloadmtk-20170518-c835c9ebe59d071485ae61df021380a980f20976.zip
mtk-20170518-c835c9ebe59d071485ae61df021380a980f20976.tar.gz
mtk-20170518-c835c9ebe59d071485ae61df021380a980f20976.tar.bz2
uhttpd: use sha256 when generating certificates with openssl (FS#512)
Patch from attachment to FS#512 Signed-off-by: Felix Fietkau <nbd@nbd.name>
-rwxr-xr-xpackage/network/services/uhttpd/files/uhttpd.init2
1 files changed, 1 insertions, 1 deletions
diff --git a/package/network/services/uhttpd/files/uhttpd.init b/package/network/services/uhttpd/files/uhttpd.init
index 53bf04c..6b8be1c 100755
--- a/package/network/services/uhttpd/files/uhttpd.init
+++ b/package/network/services/uhttpd/files/uhttpd.init
@@ -47,7 +47,7 @@ generate_keys() {
# Prefer px5g for certificate generation (existence evaluated last)
local GENKEY_CMD=""
local UNIQUEID=$(dd if=/dev/urandom bs=1 count=4 | hexdump -e '1/1 "%02x"')
- [ -x "$OPENSSL_BIN" ] && GENKEY_CMD="$OPENSSL_BIN req -x509 -outform der -nodes"
+ [ -x "$OPENSSL_BIN" ] && GENKEY_CMD="$OPENSSL_BIN req -x509 -sha256 -outform der -nodes"
[ -x "$PX5G_BIN" ] && GENKEY_CMD="$PX5G_BIN selfsigned -der"
[ -n "$GENKEY_CMD" ] && {
$GENKEY_CMD \