sshd-keygen - don't generate DSA and ED25519 host keys in FIPS mode
This commit is contained in:
parent
afde9f8153
commit
c8fc193f3d
@ -71,7 +71,7 @@ do_rsa_keygen() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
do_dsa_keygen() {
|
do_dsa_keygen() {
|
||||||
if [ ! -s $DSA_KEY ]; then
|
if [ ! -s $DSA_KEY -a `fips_enabled` -eq 0 ]; then
|
||||||
echo -n $"Generating SSH2 DSA host key: "
|
echo -n $"Generating SSH2 DSA host key: "
|
||||||
rm -f $DSA_KEY
|
rm -f $DSA_KEY
|
||||||
if test ! -f $DSA_KEY && $KEYGEN -q -t dsa -f $DSA_KEY -C '' -N '' >&/dev/null; then
|
if test ! -f $DSA_KEY && $KEYGEN -q -t dsa -f $DSA_KEY -C '' -N '' >&/dev/null; then
|
||||||
@ -113,7 +113,7 @@ do_ecdsa_keygen() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
do_ed25519_keygen() {
|
do_ed25519_keygen() {
|
||||||
if [ ! -s $ED25519_KEY ]; then
|
if [ ! -s $ED25519_KEY -a `fips_enabled` -eq 0 ]; then
|
||||||
echo -n $"Generating SSH2 ED25519 host key: "
|
echo -n $"Generating SSH2 ED25519 host key: "
|
||||||
rm -f $ED25519_KEY
|
rm -f $ED25519_KEY
|
||||||
if test ! -f $ED25519_KEY && $KEYGEN -q -t ed25519 -f $ED25519_KEY -C '' -N '' >&/dev/null; then
|
if test ! -f $ED25519_KEY && $KEYGEN -q -t ed25519 -f $ED25519_KEY -C '' -N '' >&/dev/null; then
|
||||||
|
Loading…
Reference in New Issue
Block a user