You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
586 B

diff --git a/sshd.c b/sshd.c
--- a/sshd.c
+++ b/sshd.c
@@ -1551,6 +1551,15 @@ main(int ac, char **av)
continue;
key = key_load_private(options.host_key_files[i], "", NULL);
pubkey = key_load_public(options.host_key_files[i], NULL);
+
+ if ((pubkey != NULL && pubkey->type == KEY_RSA1) ||
+ (key != NULL && key->type == KEY_RSA1)) {
+ verbose("Ignoring RSA1 key %s",
+ options.host_key_files[i]);
+ key_free(key);
+ key_free(pubkey);
+ continue;
+ }
if (pubkey == NULL && key != NULL)
pubkey = key_demote(key);
sensitive_data.host_keys[i] = key;