1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-03 22:56:33 +02:00

See ChangeLog: Tue Aug 1 20:06:23 CEST 2000 Werner Koch

This commit is contained in:
Werner Koch 2000-08-01 18:06:27 +00:00
parent 7f55ee83bb
commit b996bf9777
23 changed files with 3145 additions and 2845 deletions

View file

@ -1,3 +1,8 @@
Tue Aug 1 20:06:23 CEST 2000 Werner Koch <wk@openit.de>
* g10.c: New opttion --try-all-secrets on suggestion from Matthias Urlichs.
* pubkey-enc.c (get_session_key): Quite easy to implement here.
Thu Jul 27 17:33:04 CEST 2000 Werner Koch <wk@openit.de>
* g10.c: New option --merge-only. Suggested by Brendan O'Dea.

View file

@ -193,6 +193,7 @@ enum cmd_and_opt_values { aNull = 0,
oNoRandomSeedFile,
oNoAutoKeyRetrieve,
oMergeOnly,
oTryAllSecrets,
oEmu3DESS2KBug, /* will be removed in 1.1 */
oEmuMDEncodeBug,
aTest };
@ -378,6 +379,7 @@ static ARGPARSE_OPTS opts[] = {
{ oNoRandomSeedFile, "no-random-seed-file", 0, "@" },
{ oNoAutoKeyRetrieve, "no-auto-key-retrieve", 0, "@" },
{ oMergeOnly, "merge-only", 0, "@" },
{ oTryAllSecrets, "try-all-secrets", 0, "@" },
{ oEmu3DESS2KBug, "emulate-3des-s2k-bug", 0, "@"},
{ oEmuMDEncodeBug, "emulate-md-encode-bug", 0, "@"},
{0} };
@ -931,6 +933,7 @@ main( int argc, char **argv )
opt.override_session_key = pargs.r.ret_str;
break;
case oMergeOnly: opt.merge_only = 1; break;
case oTryAllSecrets: opt.try_all_secrets = 1; break;
default : pargs.err = configfp? 1:2; break;
}

View file

@ -94,6 +94,7 @@ struct {
const char *override_session_key;
int show_session_key;
int merge_only;
int try_all_secrets;
} opt;

View file

@ -54,7 +54,7 @@ get_session_key( PKT_pubkey_enc *k, DEK *dek )
if( rc )
goto leave;
if( k->keyid[0] || k->keyid[1] ) {
if( (k->keyid[0] || k->keyid[1]) && !opt.try_all_secrets ) {
sk = m_alloc_clear( sizeof *sk );
sk->pubkey_algo = k->pubkey_algo; /* we want a pubkey with this algo*/
if( !(rc = get_seckey( sk, k->keyid )) )