mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-03 22:56:33 +02:00
gpg: Add command --print-pka-records.
* g10/gpg.c (main): Add command --print-pka-records. * g10/options.h (struct opt): Add field "print_pka_records". * g10/keylist.c (list_keyblock_pka): New. (list_keyblock): Call it if new option is set. (print_fingerprint): Add mode 10. -- This is a fist step towards a slightly updated PKA implementation. Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
parent
93fa3d5c17
commit
e2d9340280
3 changed files with 105 additions and 3 deletions
14
g10/gpg.c
14
g10/gpg.c
|
@ -131,6 +131,7 @@ enum cmd_and_opt_values
|
|||
aSendKeys,
|
||||
aRecvKeys,
|
||||
aLocateKeys,
|
||||
aPrintPKARecords,
|
||||
aSearchKeys,
|
||||
aRefreshKeys,
|
||||
aFetchKeys,
|
||||
|
@ -407,6 +408,7 @@ static ARGPARSE_OPTS opts[] = {
|
|||
ARGPARSE_c (aCheckKeys, "check-sigs",N_("list and check key signatures")),
|
||||
ARGPARSE_c (oFingerprint, "fingerprint", N_("list keys and fingerprints")),
|
||||
ARGPARSE_c (aListSecretKeys, "list-secret-keys", N_("list secret keys")),
|
||||
ARGPARSE_c (aPrintPKARecords, "print-pka-records", "@"),
|
||||
ARGPARSE_c (aKeygen, "gen-key",
|
||||
N_("generate a new key pair")),
|
||||
ARGPARSE_c (aQuickKeygen, "quick-gen-key" ,
|
||||
|
@ -2312,6 +2314,11 @@ main (int argc, char **argv)
|
|||
set_cmd (&cmd, pargs.r_opt);
|
||||
break;
|
||||
|
||||
case aPrintPKARecords:
|
||||
set_cmd (&cmd, pargs.r_opt);
|
||||
opt.print_pka_records = 1;
|
||||
break;
|
||||
|
||||
case aKeygen:
|
||||
case aFullKeygen:
|
||||
case aEditKey:
|
||||
|
@ -3857,6 +3864,13 @@ main (int argc, char **argv)
|
|||
public_key_list (ctrl, sl, 1);
|
||||
free_strlist (sl);
|
||||
break;
|
||||
case aPrintPKARecords:
|
||||
sl = NULL;
|
||||
for (; argc; argc--, argv++)
|
||||
add_to_strlist2( &sl, *argv, utf8_strings );
|
||||
public_key_list (ctrl, sl, 0);
|
||||
free_strlist (sl);
|
||||
break;
|
||||
|
||||
case aQuickKeygen:
|
||||
if (argc != 1 )
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue