diff options
author | Darren Tucker <dtucker@zip.com.au> | 2005-11-29 03:10:24 +0100 |
---|---|---|
committer | Darren Tucker <dtucker@zip.com.au> | 2005-11-29 03:10:24 +0100 |
commit | 3af2ac56a28dd49226388505b5ebbfc778335f9c (patch) | |
tree | ce32ed5fce4190ac16491831967a62c509295c9c /ssh-keygen.c | |
parent | - (tim) [ssh-keygen.c] Move DSA length test after setting default when (diff) | |
download | openssh-3af2ac56a28dd49226388505b5ebbfc778335f9c.tar.xz openssh-3af2ac56a28dd49226388505b5ebbfc778335f9c.zip |
- dtucker@cvs.openbsd.org 2005/11/29 02:04:55
[ssh-keygen.c]
Populate default key sizes before checking them; from & ok tim@
Diffstat (limited to '')
-rw-r--r-- | ssh-keygen.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ssh-keygen.c b/ssh-keygen.c index 3a6174ac1..64fadc7a1 100644 --- a/ssh-keygen.c +++ b/ssh-keygen.c @@ -12,7 +12,7 @@ */ #include "includes.h" -RCSID("$OpenBSD: ssh-keygen.c,v 1.134 2005/11/28 05:16:53 dtucker Exp $"); +RCSID("$OpenBSD: ssh-keygen.c,v 1.135 2005/11/29 02:04:55 dtucker Exp $"); #include <openssl/evp.h> #include <openssl/pem.h> @@ -1259,12 +1259,12 @@ main(int ac, char **av) fprintf(stderr, "unknown key type %s\n", key_type_name); exit(1); } - if (!quiet) - printf("Generating public/private %s key pair.\n", key_type_name); if (bits == 0) bits = (type == KEY_DSA) ? DEFAULT_BITS_DSA : DEFAULT_BITS; if (type == KEY_DSA && bits != 1024) fatal("DSA keys must be 1024 bits"); + if (!quiet) + printf("Generating public/private %s key pair.\n", key_type_name); private = key_generate(type, bits); if (private == NULL) { fprintf(stderr, "key_generate failed"); |