g10: Fix keysize with --expert.
authorNIIBE Yutaka <gniibe@fsij.org>
Wed, 6 Jul 2016 02:45:05 +0000 (11:45 +0900)
committerNIIBE Yutaka <gniibe@fsij.org>
Wed, 6 Jul 2016 02:45:05 +0000 (11:45 +0900)
* g10/keygen.c (ask_keysize): It's 768 only for DSA.

--

GnuPG-bug-id: 2238
Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
g10/keygen.c

index 76ee74e..268fce5 100644 (file)
@@ -1582,8 +1582,8 @@ ask_keysize (int algo, unsigned int primary_keysize)
   int for_subkey = !!primary_keysize;
   int autocomp = 0;
 
-  if(opt.expert)
-    min=512;
+  if(opt.expert && algo == PUBKEY_ALGO_DSA)
+    min=768;
   else
     min=1024;