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

* trustdb.h, trustdb.c (register_trusted_keyid): New. Adds a keyid to the

list of ultimately trusted keys.

* keygen.c (do_generate_keypair): Use it here so that the ultimate
ownertrust happens before the trustdb (might be) rebuilt.  Also fix an
error where the newly generated pk is thought to be a subkey by the
trustdb.

* g10.c (main): Fix --export-all do actually do something different than
--export.

* pkclist.c (build_pk_list): Show all recipients rather than showing each
recipient as they are added.

* mainproc.c (proc_symkey_enc, proc_encrypted): Keep a count of the number
of passphrases that can decrypt a symmetric or mixed symmetric/pk message
and include it in the list of keys shown to the user.
This commit is contained in:
David Shaw 2003-11-01 01:13:16 +00:00
parent d3cd27c3b6
commit 5c37fd90bf
7 changed files with 94 additions and 44 deletions

View file

@ -204,22 +204,30 @@ release_key_array ( struct key_array *keys )
* before initializing the validation module.
* FIXME: Should be replaced by a function to add those keys to the trustdb.
*/
void
register_trusted_keyid(u32 *keyid)
{
struct key_item *k;
k = new_key_item ();
k->kid[0] = keyid[0];
k->kid[1] = keyid[1];
k->next = user_utk_list;
user_utk_list = k;
}
void
register_trusted_key( const char *string )
{
KEYDB_SEARCH_DESC desc;
struct key_item *k;
if (classify_user_id (string, &desc) != KEYDB_SEARCH_MODE_LONG_KID ) {
log_error(_("`%s' is not a valid long keyID\n"), string );
return;
}
if (classify_user_id (string, &desc) != KEYDB_SEARCH_MODE_LONG_KID )
{
log_error(_("`%s' is not a valid long keyID\n"), string );
return;
}
k = new_key_item ();
k->kid[0] = desc.u.kid[0];
k->kid[1] = desc.u.kid[1];
k->next = user_utk_list;
user_utk_list = k;
register_trusted_keyid(desc.u.kid);
}
/*