1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-02 22:46:30 +02:00

Backported some stuff from trunk

This commit is contained in:
Werner Koch 2009-12-03 19:39:39 +00:00
parent 1356693b0d
commit ae7b03d427
13 changed files with 390 additions and 58 deletions

View file

@ -3,6 +3,8 @@
* gpg.c (set_debug): Allow for numerical debug levels. Print
active debug flags.
* gpg.c (gpgconf_list): Add key "default_pubkey_algo".
2009-09-28 Werner Koch <wk@g10code.com>
* trustdb.c (get_validity_info): Take care of a NULL PK. Fixes

View file

@ -1613,6 +1613,11 @@ gpgconf_list (const char *configfile)
printf ("debug-level:%lu:\"none:\n", GC_OPT_FLAG_DEFAULT);
printf ("group:%lu:\n", GC_OPT_FLAG_NONE);
/* The next one is an info only item and should match what
keygen:ask_keysize actually implements. */
printf ("default_pubkey_algo:%lu:\"%s:\n", GC_OPT_FLAG_DEFAULT,
"RSA-2048");
xfree (configfile_esc);
}

View file

@ -1765,6 +1765,8 @@ ask_algo (int addmode, int *r_subkey_algo, unsigned int *r_usage)
static unsigned
ask_keysize (int algo, unsigned int primary_keysize)
{
/* NOTE: If you change the default key size/algo, remember to change
it also in gpg.c:gpgconf_list. */
unsigned int nbits, min, def=2048, max=4096;
int for_subkey = !!primary_keysize;
int autocomp = 0;