diff options
| author | Werner Koch <[email protected]> | 2025-07-24 12:12:37 +0000 |
|---|---|---|
| committer | Werner Koch <[email protected]> | 2025-07-24 12:15:08 +0000 |
| commit | e3cc410003a91e7ab4c267e1285c0c4c57775be9 (patch) | |
| tree | b7e3a38721ce846352ce76bf4d277f5972eaa6ac /g10/gpgv.c | |
| parent | gpgsm: Fix caching of the trustlist's flags. (diff) | |
| download | gnupg-e3cc410003a91e7ab4c267e1285c0c4c57775be9.tar.gz gnupg-e3cc410003a91e7ab4c267e1285c0c4c57775be9.zip | |
gpgv: New option --print-notation.
* g10/keylist.c (print_matching_notations): New.
* g10/mainproc.c (check_sig_and_print): Call this.
* g10/options.h (opt): Add field print_notations.
* g10/gpgv.c (oPrintNotation): New.
(opts): Add "print-notation".
(main): Implement.
--
I had the code floating around but can't remember what triggered me to
write this. But it might eventually be useful, so better apply it.
Diffstat (limited to 'g10/gpgv.c')
| -rw-r--r-- | g10/gpgv.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/g10/gpgv.c b/g10/gpgv.c index 6d3d25f50..686fc8891 100644 --- a/g10/gpgv.c +++ b/g10/gpgv.c @@ -58,6 +58,7 @@ enum cmd_and_opt_values { oQuiet = 'q', oVerbose = 'v', oOutput = 'o', + oPrintNotation = 'N', oBatch = 500, oKeyring, oIgnoreTimeConflict, @@ -91,6 +92,8 @@ static gpgrt_opt_t opts[] = { ARGPARSE_s_s (oWeakDigest, "weak-digest", N_("|ALGO|reject signatures made with ALGO")), ARGPARSE_s_n (oEnableSpecialFilenames, "enable-special-filenames", "@"), + ARGPARSE_s_s (oPrintNotation, "print-notation", + N_("|NAME|print the notation NAME to stdout")), ARGPARSE_s_s (oDebug, "debug", "@"), ARGPARSE_s_s (oAssertPubkeyAlgo,"assert-pubkey-algo", "@"), @@ -267,6 +270,10 @@ main( int argc, char **argv ) } break; + case oPrintNotation: + append_to_strlist (&opt.print_notations, pargs.r.ret_str); + break; + default : pargs.err = ARGPARSE_PRINT_ERROR; break; } } |
