aboutsummaryrefslogtreecommitdiffstats
path: root/g10/gpg.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2024-04-17 09:42:20 +0000
committerWerner Koch <[email protected]>2024-04-17 09:42:20 +0000
commit21f7ad563d9bcb6d295e8f313f29b14238e7481f (patch)
tree544f62b33f36a0b833206140b197b4b0900c8ea2 /g10/gpg.c
parentgpg: Make --with-subkey-fingerprint the default. (diff)
downloadgnupg-21f7ad563d9bcb6d295e8f313f29b14238e7481f.tar.gz
gnupg-21f7ad563d9bcb6d295e8f313f29b14238e7481f.zip
gpg: New command --quick-set-ownertrust.
* g10/gpg.c (aQuickSetOwnertrust): New. (opts): Add new command. (main): Implement it. * g10/keyedit.c (keyedit_quick_set_ownertrust): New.
Diffstat (limited to 'g10/gpg.c')
-rw-r--r--g10/gpg.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/g10/gpg.c b/g10/gpg.c
index e8894ab4a..7cb83c443 100644
--- a/g10/gpg.c
+++ b/g10/gpg.c
@@ -136,6 +136,7 @@ enum cmd_and_opt_values
aQuickSetExpire,
aQuickSetPrimaryUid,
aQuickUpdatePref,
+ aQuickSetOwnertrust,
aListConfig,
aListGcryptConfig,
aGPGConfList,
@@ -504,6 +505,7 @@ static gpgrt_opt_t opts[] = {
N_("quickly set a new expiration date")),
ARGPARSE_c (aQuickSetPrimaryUid, "quick-set-primary-uid", "@"),
ARGPARSE_c (aQuickUpdatePref, "quick-update-pref", "@"),
+ ARGPARSE_c (aQuickSetOwnertrust, "quick-set-ownertrust", "@"),
ARGPARSE_c (aFullKeygen, "full-generate-key" ,
N_("full featured key pair generation")),
ARGPARSE_c (aFullKeygen, "full-gen-key", "@"),
@@ -2722,6 +2724,7 @@ main (int argc, char **argv)
case aQuickSetExpire:
case aQuickSetPrimaryUid:
case aQuickUpdatePref:
+ case aQuickSetOwnertrust:
case aExportOwnerTrust:
case aImportOwnerTrust:
case aRebuildKeydbCaches:
@@ -4405,6 +4408,7 @@ main (int argc, char **argv)
case aQuickRevUid:
case aQuickSetPrimaryUid:
case aQuickUpdatePref:
+ case aQuickSetOwnertrust:
case aFullKeygen:
case aKeygen:
case aImport:
@@ -4926,6 +4930,15 @@ main (int argc, char **argv)
}
break;
+ case aQuickSetOwnertrust:
+ {
+ if (argc != 2)
+ wrong_args ("--quick-set-ownertrust USER-ID"
+ " [enable|disable|full|...]");
+ keyedit_quick_set_ownertrust (ctrl, argv[0], argv[1]);
+ }
+ break;
+
case aFastImport:
opt.import_options |= IMPORT_FAST; /* fall through */
case aImport: