1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-02 22:46:30 +02:00

gpg: Make --with-subkey-fingerprint the default.

* g10/gpg.c (oWithoutSubkeyFingerprint): New.
(opts): Add "without-subkey-fingerprint".
(main): Make --with-subkey-fingerprint the default.  Implementation
the without option.
--

Given that the default for the keyid format is none, the subkey
fingerprints are important to do anything with a subkey.  Thus we make
the old option the default and provide a new option to revert it.
This commit is contained in:
Werner Koch 2024-04-16 18:31:29 +02:00
parent 4e32ff209d
commit 2a71c3cf97
No known key found for this signature in database
GPG key ID: E3FDFF218E45B72B
2 changed files with 11 additions and 2 deletions

View file

@ -206,6 +206,7 @@ enum cmd_and_opt_values
oWithV5Fingerprint,
oWithFingerprint,
oWithSubkeyFingerprint,
oWithoutSubkeyFingerprint,
oWithICAOSpelling,
oWithKeygrip,
oWithKeyScreening,
@ -824,6 +825,7 @@ static gpgrt_opt_t opts[] = {
ARGPARSE_s_n (oWithFingerprint, "with-fingerprint", "@"),
ARGPARSE_s_n (oWithSubkeyFingerprint, "with-subkey-fingerprint", "@"),
ARGPARSE_s_n (oWithSubkeyFingerprint, "with-subkey-fingerprints", "@"),
ARGPARSE_s_n (oWithoutSubkeyFingerprint, "without-subkey-fingerprint", "@"),
ARGPARSE_s_n (oWithICAOSpelling, "with-icao-spelling", "@"),
ARGPARSE_s_n (oWithKeygrip, "with-keygrip", "@"),
ARGPARSE_s_n (oWithKeyScreening,"with-key-screening", "@"),
@ -2503,6 +2505,7 @@ main (int argc, char **argv)
opt.passphrase_repeat = 1;
opt.emit_version = 0;
opt.weak_digests = NULL;
opt.with_subkey_fingerprint = 1;
opt.compliance = CO_GNUPG;
/* Check special options given on the command line. */
@ -2909,6 +2912,9 @@ main (int argc, char **argv)
case oWithSubkeyFingerprint:
opt.with_subkey_fingerprint = 1;
break;
case oWithoutSubkeyFingerprint:
opt.with_subkey_fingerprint = 0;
break;
case oWithICAOSpelling:
opt.with_icao_spelling = 1;
break;