summaryrefslogtreecommitdiff
path: root/usr.bin/ssh/readconf.c
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2001-02-24 10:37:56 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2001-02-24 10:37:56 +0000
commitaa9ea84776f75cbc8aed1f18969da47d0f90b484 (patch)
tree7df57b2e42d096ce3ba907e14e902c7701a6c650 /usr.bin/ssh/readconf.c
parentda4ca07328e82110a68a5e535d9b7b06998efa87 (diff)
look for id_rsa by default, before id_dsa
Diffstat (limited to 'usr.bin/ssh/readconf.c')
-rw-r--r--usr.bin/ssh/readconf.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/usr.bin/ssh/readconf.c b/usr.bin/ssh/readconf.c
index 359b8264982..40c1b700eb3 100644
--- a/usr.bin/ssh/readconf.c
+++ b/usr.bin/ssh/readconf.c
@@ -12,7 +12,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: readconf.c,v 1.62 2001/02/11 12:59:25 markus Exp $");
+RCSID("$OpenBSD: readconf.c,v 1.63 2001/02/24 10:37:55 deraadt Exp $");
#include "ssh.h"
#include "xmalloc.h"
@@ -806,6 +806,12 @@ fill_default_options(Options * options)
len, "~/%.100s", _PATH_SSH_CLIENT_IDENTITY);
}
if (options->protocol & SSH_PROTO_2) {
+ len = 2 + strlen(_PATH_SSH_CLIENT_ID_RSA) + 1;
+ options->identity_files[options->num_identity_files] =
+ xmalloc(len);
+ snprintf(options->identity_files[options->num_identity_files++],
+ len, "~/%.100s", _PATH_SSH_CLIENT_ID_RSA);
+
len = 2 + strlen(_PATH_SSH_CLIENT_ID_DSA) + 1;
options->identity_files[options->num_identity_files] =
xmalloc(len);