1
0
angie-conv-image/scripts/openssl-generate-dh-bundle.sh

17 lines
435 B
Bash
Raw Permalink Normal View History

2024-09-17 14:11:00 +03:00
#!/bin/sh
set -ef
for k in 1024 2048 ; do
f="dh${k}.pem"
echo "# openssl genpkey: $f" >&2
timeout --kill-after=32s 30s \
openssl genpkey -quiet -genparam -algorithm DH -out "./$f" -pkeyopt "dh_paramgen_prime_len:${k}"
done
for k in 2048 3072 4096 ; do
f="ffdhe${k}.pem"
echo "# openssl genpkey: $f" >&2
timeout --kill-after=32s 30s \
openssl genpkey -quiet -genparam -algorithm DH -out "./$f" -pkeyopt "group:ffdhe${k}"
done