diff options
author | Tim Rice <tim@multitalents.net> | 2005-11-29 02:45:32 +0100 |
---|---|---|
committer | Tim Rice <tim@multitalents.net> | 2005-11-29 02:45:32 +0100 |
commit | 660c3405f95fa3f1169cbeaba2bc74a37bcbea9e (patch) | |
tree | d2ebdde691985bb204dcad62d4ff5833336a1eb0 | |
parent | - (dtucker) [includes.h] Bug #1122: __USE_GNU is a glibc internal macro, use (diff) | |
download | openssh-660c3405f95fa3f1169cbeaba2bc74a37bcbea9e.tar.xz openssh-660c3405f95fa3f1169cbeaba2bc74a37bcbea9e.zip |
- (tim) [ssh-keygen.c] Move DSA length test after setting default when
bits == 0.
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | ssh-keygen.c | 4 |
2 files changed, 7 insertions, 3 deletions
@@ -1,3 +1,7 @@ +20051129 + - (tim) [ssh-keygen.c] Move DSA length test after setting default when + bits == 0. + 20051128 - (dtucker) [regress/yes-head.sh] Work around breakage caused by some versions of GNU head. Based on patch from zappaman at buraphalinux.org @@ -3375,4 +3379,4 @@ - (djm) Trim deprecated options from INSTALL. Mention UsePAM - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu -$Id: ChangeLog,v 1.4012 2005/11/28 11:28:59 dtucker Exp $ +$Id: ChangeLog,v 1.4013 2005/11/29 01:45:32 tim Exp $ diff --git a/ssh-keygen.c b/ssh-keygen.c index b4c651d22..3a6174ac1 100644 --- a/ssh-keygen.c +++ b/ssh-keygen.c @@ -1259,12 +1259,12 @@ main(int ac, char **av) fprintf(stderr, "unknown key type %s\n", key_type_name); exit(1); } - 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); 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"); private = key_generate(type, bits); if (private == NULL) { fprintf(stderr, "key_generate failed"); |