summaryrefslogtreecommitdiff
path: root/ssh-keygen.c
diff options
context:
space:
mode:
Diffstat (limited to 'ssh-keygen.c')
-rw-r--r--ssh-keygen.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/ssh-keygen.c b/ssh-keygen.c
index 7f9c7fd1a..b4c651d22 100644
--- a/ssh-keygen.c
+++ b/ssh-keygen.c
@@ -12,7 +12,7 @@
12 */ 12 */
13 13
14#include "includes.h" 14#include "includes.h"
15RCSID("$OpenBSD: ssh-keygen.c,v 1.133 2005/10/31 11:12:49 djm Exp $"); 15RCSID("$OpenBSD: ssh-keygen.c,v 1.134 2005/11/28 05:16:53 dtucker Exp $");
16 16
17#include <openssl/evp.h> 17#include <openssl/evp.h>
18#include <openssl/pem.h> 18#include <openssl/pem.h>
@@ -1046,7 +1046,7 @@ main(int ac, char **av)
1046 "degiqpclBHvxXyF:b:f:t:U:D:P:N:C:r:g:R:T:G:M:S:a:W:")) != -1) { 1046 "degiqpclBHvxXyF:b:f:t:U:D:P:N:C:r:g:R:T:G:M:S:a:W:")) != -1) {
1047 switch (opt) { 1047 switch (opt) {
1048 case 'b': 1048 case 'b':
1049 bits = strtonum(optarg, 512, 32768, &errstr); 1049 bits = strtonum(optarg, 768, 32768, &errstr);
1050 if (errstr) 1050 if (errstr)
1051 fatal("Bits has bad value %s (%s)", 1051 fatal("Bits has bad value %s (%s)",
1052 optarg, errstr); 1052 optarg, errstr);
@@ -1259,6 +1259,8 @@ main(int ac, char **av)
1259 fprintf(stderr, "unknown key type %s\n", key_type_name); 1259 fprintf(stderr, "unknown key type %s\n", key_type_name);
1260 exit(1); 1260 exit(1);
1261 } 1261 }
1262 if (type == KEY_DSA && bits != 1024)
1263 fatal("DSA keys must be 1024 bits");
1262 if (!quiet) 1264 if (!quiet)
1263 printf("Generating public/private %s key pair.\n", key_type_name); 1265 printf("Generating public/private %s key pair.\n", key_type_name);
1264 if (bits == 0) 1266 if (bits == 0)