summaryrefslogtreecommitdiff
path: root/sshconnect2.c
diff options
context:
space:
mode:
Diffstat (limited to 'sshconnect2.c')
-rw-r--r--sshconnect2.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sshconnect2.c b/sshconnect2.c
index d045365f3..8a9887a2e 100644
--- a/sshconnect2.c
+++ b/sshconnect2.c
@@ -1421,6 +1421,8 @@ pubkey_prepare(Authctxt *authctxt)
1421 1421
1422 /* list of keys stored in the filesystem */ 1422 /* list of keys stored in the filesystem */
1423 for (i = 0; i < options.num_identity_files; i++) { 1423 for (i = 0; i < options.num_identity_files; i++) {
1424 if (options.identity_files[i] == NULL)
1425 continue;
1424 key = options.identity_keys[i]; 1426 key = options.identity_keys[i];
1425 if (key && key->type == KEY_RSA1) 1427 if (key && key->type == KEY_RSA1)
1426 continue; 1428 continue;
@@ -1514,7 +1516,7 @@ userauth_pubkey(Authctxt *authctxt)
1514 debug("Offering %s public key: %s", key_type(id->key), 1516 debug("Offering %s public key: %s", key_type(id->key),
1515 id->filename); 1517 id->filename);
1516 sent = send_pubkey_test(authctxt, id); 1518 sent = send_pubkey_test(authctxt, id);
1517 } else if (id->key == NULL) { 1519 } else if (id->key == NULL && id->filename) {
1518 debug("Trying private key: %s", id->filename); 1520 debug("Trying private key: %s", id->filename);
1519 id->key = load_identity_file(id->filename); 1521 id->key = load_identity_file(id->filename);
1520 if (id->key != NULL) { 1522 if (id->key != NULL) {