mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-03 22:56:33 +02:00
gpg: New option --show-only-session-key
* g10/options.h (opt): Add show_only_session_key and turn show_session_key into a bit flag. * g10/gpg.c (oShowOnlySessionKey): New. (opts): Add "show-only-session-key". (main): Set flag. * g10/mainproc.c (proc_encrypted): Handle the new option. * g10/decrypt-data.c (decrypt_data): Ditto. Add compliance error flag to the DECRYPTION_INFO status line. -- This new option is somehow related to GnuPG-bug-id: 1825
This commit is contained in:
parent
4c65dfeb28
commit
1695cf267e
6 changed files with 42 additions and 13 deletions
10
g10/gpg.c
10
g10/gpg.c
|
@ -367,6 +367,7 @@ enum cmd_and_opt_values
|
|||
oIgnoreCrcError,
|
||||
oIgnoreMDCError,
|
||||
oShowSessionKey,
|
||||
oShowOnlySessionKey,
|
||||
oOverrideSessionKey,
|
||||
oOverrideSessionKeyFD,
|
||||
oNoRandomSeedFile,
|
||||
|
@ -770,6 +771,7 @@ static gpgrt_opt_t opts[] = {
|
|||
ARGPARSE_s_n (oShowNotation, "show-notation", "@"),
|
||||
ARGPARSE_s_n (oNoShowNotation, "no-show-notation", "@"),
|
||||
ARGPARSE_s_n (oShowSessionKey, "show-session-key", "@"),
|
||||
ARGPARSE_s_n (oShowOnlySessionKey, "show-only-session-key", "@"),
|
||||
ARGPARSE_s_n (oUseEmbeddedFilename, "use-embedded-filename", "@"),
|
||||
ARGPARSE_s_n (oNoUseEmbeddedFilename, "no-use-embedded-filename", "@"),
|
||||
ARGPARSE_s_n (oUnwrap, "unwrap", "@"),
|
||||
|
@ -3564,7 +3566,13 @@ main (int argc, char **argv)
|
|||
opt.keyserver_options.options &= ~KEYSERVER_AUTO_KEY_RETRIEVE;
|
||||
break;
|
||||
|
||||
case oShowSessionKey: opt.show_session_key = 1; break;
|
||||
case oShowOnlySessionKey:
|
||||
opt.show_only_session_key = 1;
|
||||
/* fallthru */
|
||||
case oShowSessionKey:
|
||||
opt.show_session_key = 1;
|
||||
break;
|
||||
|
||||
case oOverrideSessionKey:
|
||||
opt.override_session_key = pargs.r.ret_str;
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue