mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
Allow generation of DSA2 keys without --enable-dsa2.
This commit is contained in:
parent
ad6326185e
commit
556d4ed983
4 changed files with 17 additions and 16 deletions
|
@ -1,8 +1,12 @@
|
|||
2009-05-20 Werner Koch <wk@g10code.com>
|
||||
|
||||
* keygen.c (ask_keysize): Allow selection of DSA key size even
|
||||
without --enable-dsa2.
|
||||
(gen_dsa): Remove size check.
|
||||
|
||||
* keygen.c (ask_key_flags): Fix bug in the translation check.
|
||||
Fixes bug#1056.
|
||||
|
||||
|
||||
2009-05-18 Daiki Ueno <ueno@unixuser.org> (wk)
|
||||
|
||||
* encode.c (encode_simple): Tell passphrase_to_dek to cache
|
||||
|
|
14
g10/keygen.c
14
g10/keygen.c
|
@ -1263,7 +1263,7 @@ gen_dsa (unsigned int nbits, KBNODE pub_root, KBNODE sec_root, DEK *dek,
|
|||
gcry_sexp_t misc_key_info;
|
||||
unsigned int qbits;
|
||||
|
||||
if ( nbits < 512 || (!opt.flags.dsa2 && nbits > 1024))
|
||||
if ( nbits < 512)
|
||||
{
|
||||
nbits = 1024;
|
||||
log_info(_("keysize invalid; using %u bits\n"), nbits );
|
||||
|
@ -1768,16 +1768,8 @@ ask_keysize (int algo, unsigned int primary_keysize)
|
|||
switch(algo)
|
||||
{
|
||||
case PUBKEY_ALGO_DSA:
|
||||
if(opt.flags.dsa2)
|
||||
{
|
||||
def=2048;
|
||||
max=3072;
|
||||
}
|
||||
else
|
||||
{
|
||||
tty_printf(_("DSA keypair will have %u bits.\n"),1024);
|
||||
return 1024;
|
||||
}
|
||||
def=2048;
|
||||
max=3072;
|
||||
break;
|
||||
|
||||
case PUBKEY_ALGO_RSA:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue