1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-03 22:56:33 +02:00

agent: Add option --status to the LISTRUSTED command.

* agent/trustlist.c (istrusted_internal): Add arg listmode and print
new status line in this mode.  Adjust callers.
(agent_listtrusted): Add new args ctrl and status_mode.  Get all
trusted keys and then call is_trusted_internal for all of them.

* agent/command.c (cmd_listtrusted): Add new option --status.
--

This allows in a non-restricted connection to list all trusted keys in
one go.
This commit is contained in:
Werner Koch 2024-10-01 18:07:32 +02:00
parent f50dde6269
commit 4275d5fa7a
No known key found for this signature in database
GPG key ID: E3FDFF218E45B72B
3 changed files with 60 additions and 16 deletions

View file

@ -637,7 +637,8 @@ gpg_error_t agent_write_shadow_key (ctrl_t ctrl, const unsigned char *grip,
/*-- trustlist.c --*/
void initialize_module_trustlist (void);
gpg_error_t agent_istrusted (ctrl_t ctrl, const char *fpr, int *r_disabled);
gpg_error_t agent_listtrusted (void *assuan_context);
gpg_error_t agent_listtrusted (ctrl_t ctrl, void *assuan_context,
int status_mode);
gpg_error_t agent_marktrusted (ctrl_t ctrl, const char *name,
const char *fpr, int flag);
void agent_reload_trustlist (void);