diff --git a/g10/ChangeLog b/g10/ChangeLog index 017150c1e..466bd760b 100644 --- a/g10/ChangeLog +++ b/g10/ChangeLog @@ -1,3 +1,19 @@ +2004-03-19 David Shaw + + * trustdb.c (update_min_ownertrust, validate_keys): Do not use + keystr functions in log_debug. + + * import.c (import_one): Try and collapse user IDs when importing + a key for the first time. + + * keyedit.c (menu_addrevoker): Allow appointing a subkey as a + designated revoker if the user forces it via keyid!, so long as + the subkey can certify. Also use the proper date string when + prompting for confirmation. + + * g10.c (main): Maintain ordering of multiple Comment lines. + Requested by Peter Hyman. + 2004-03-17 David Shaw * mainproc.c (proc_pubkey_enc, print_pkenc_list, list_node): diff --git a/g10/g10.c b/g10/g10.c index 3e5dd2950..4e1c36bbf 100644 --- a/g10/g10.c +++ b/g10/g10.c @@ -1929,7 +1929,7 @@ main( int argc, char **argv ) case oUseEmbeddedFilename: opt.use_embedded_filename = 1; break; case oComment: if(pargs.r.ret_str[0]) - add_to_strlist(&opt.comments,pargs.r.ret_str); + append_to_strlist(&opt.comments,pargs.r.ret_str); break; case oDefaultComment: deprecated_warning(configname,configlineno, diff --git a/g10/import.c b/g10/import.c index b5a933937..c1110bff6 100644 --- a/g10/import.c +++ b/g10/import.c @@ -758,6 +758,9 @@ import_one( const char *fname, KBNODE keyblock, } if( opt.verbose > 1 ) log_info (_("writing to `%s'\n"), keydb_get_resource_name (hd) ); + + collapse_uids(&keyblock); + rc = keydb_insert_keyblock (hd, keyblock ); if (rc) log_error (_("error writing keyring `%s': %s\n"), diff --git a/g10/keyedit.c b/g10/keyedit.c index 0b648dc9a..9b488b059 100644 --- a/g10/keyedit.c +++ b/g10/keyedit.c @@ -2685,8 +2685,10 @@ menu_addrevoker( KBNODE pub_keyblock, KBNODE sec_keyblock, int sensitive ) goto fail; } + /* Note that I'm requesting SIG here and not CERT. We're making + a certification, but it is okay to be a subkey. */ + revoker_pk->req_usage=PUBKEY_USAGE_SIG; rc=get_pubkey_byname(revoker_pk,answer,NULL,NULL,1); - if(rc) { log_error (_("key `%s' not found: %s\n"),answer,g10_errstr(rc)); @@ -2756,7 +2758,7 @@ menu_addrevoker( KBNODE pub_keyblock, KBNODE sec_keyblock, int sensitive ) tty_printf("\npub %4u%c/%08lX %s ", nbits_from_pk( revoker_pk ), pubkey_letter( revoker_pk->pubkey_algo ), - (ulong)keyid[1], datestr_from_pk(pk) ); + (ulong)keyid[1], datestr_from_pk(revoker_pk) ); p = get_user_id( keyid, &n ); tty_print_utf8_string( p, n ); diff --git a/g10/trustdb.c b/g10/trustdb.c index 67f9211fd..5cb69ccfe 100644 --- a/g10/trustdb.c +++ b/g10/trustdb.c @@ -797,8 +797,9 @@ update_min_ownertrust (u32 *kid, unsigned int new_trust ) if (!rc) { if (DBG_TRUST) - log_debug ("key %s: update min_ownertrust from %u to %u\n", - keystr(kid),(unsigned int)rec.r.trust.min_ownertrust, + log_debug ("key %08lX%08lX: update min_ownertrust from %u to %u\n", + (ulong)kid[0],(ulong)kid[1], + (unsigned int)rec.r.trust.min_ownertrust, new_trust ); if (rec.r.trust.min_ownertrust != new_trust) { @@ -1985,9 +1986,9 @@ validate_keys (int interactive) if(k->ownertrustkid), + (ulong)k->kid[0],(ulong)k->kid[1], trust_value_to_string(k->ownertrust), trust_value_to_string(min));