1
0
mirror of git://git.gnupg.org/gnupg.git synced 2025-01-05 12:31:50 +01:00

* 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.
This commit is contained in:
David Shaw 2004-03-19 23:15:27 +00:00
parent ba3f9044d3
commit 36a5e54e54
5 changed files with 29 additions and 7 deletions

View File

@ -1,3 +1,19 @@
2004-03-19 David Shaw <dshaw@jabberwocky.com>
* 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 <dshaw@jabberwocky.com> 2004-03-17 David Shaw <dshaw@jabberwocky.com>
* mainproc.c (proc_pubkey_enc, print_pkenc_list, list_node): * mainproc.c (proc_pubkey_enc, print_pkenc_list, list_node):

View File

@ -1929,7 +1929,7 @@ main( int argc, char **argv )
case oUseEmbeddedFilename: opt.use_embedded_filename = 1; break; case oUseEmbeddedFilename: opt.use_embedded_filename = 1; break;
case oComment: case oComment:
if(pargs.r.ret_str[0]) 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; break;
case oDefaultComment: case oDefaultComment:
deprecated_warning(configname,configlineno, deprecated_warning(configname,configlineno,

View File

@ -758,6 +758,9 @@ import_one( const char *fname, KBNODE keyblock,
} }
if( opt.verbose > 1 ) if( opt.verbose > 1 )
log_info (_("writing to `%s'\n"), keydb_get_resource_name (hd) ); log_info (_("writing to `%s'\n"), keydb_get_resource_name (hd) );
collapse_uids(&keyblock);
rc = keydb_insert_keyblock (hd, keyblock ); rc = keydb_insert_keyblock (hd, keyblock );
if (rc) if (rc)
log_error (_("error writing keyring `%s': %s\n"), log_error (_("error writing keyring `%s': %s\n"),

View File

@ -2685,8 +2685,10 @@ menu_addrevoker( KBNODE pub_keyblock, KBNODE sec_keyblock, int sensitive )
goto fail; 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); rc=get_pubkey_byname(revoker_pk,answer,NULL,NULL,1);
if(rc) if(rc)
{ {
log_error (_("key `%s' not found: %s\n"),answer,g10_errstr(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 ", tty_printf("\npub %4u%c/%08lX %s ",
nbits_from_pk( revoker_pk ), nbits_from_pk( revoker_pk ),
pubkey_letter( revoker_pk->pubkey_algo ), 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 ); p = get_user_id( keyid, &n );
tty_print_utf8_string( p, n ); tty_print_utf8_string( p, n );

View File

@ -797,8 +797,9 @@ update_min_ownertrust (u32 *kid, unsigned int new_trust )
if (!rc) if (!rc)
{ {
if (DBG_TRUST) if (DBG_TRUST)
log_debug ("key %s: update min_ownertrust from %u to %u\n", log_debug ("key %08lX%08lX: update min_ownertrust from %u to %u\n",
keystr(kid),(unsigned int)rec.r.trust.min_ownertrust, (ulong)kid[0],(ulong)kid[1],
(unsigned int)rec.r.trust.min_ownertrust,
new_trust ); new_trust );
if (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->ownertrust<min) if(k->ownertrust<min)
{ {
if(DBG_TRUST) if(DBG_TRUST)
log_debug("key %s:" log_debug("key %08lX%08lX:"
" overriding ownertrust \"%s\" with \"%s\"\n", " overriding ownertrust \"%s\" with \"%s\"\n",
keystr(k->kid), (ulong)k->kid[0],(ulong)k->kid[1],
trust_value_to_string(k->ownertrust), trust_value_to_string(k->ownertrust),
trust_value_to_string(min)); trust_value_to_string(min));