From 00f30cc01c79bbdff5cdc3be795f009f15d3845e Mon Sep 17 00:00:00 2001 From: Daniel Kahn Gillmor Date: Fri, 10 Jun 2016 16:15:33 -0400 Subject: g10: report whether key in agent is passphrase-protected or not * g10/call-agent.c, g10/call-agent.h (agent_get_keyinfo): add r_cleartext parameter to report whether a key is stored without passphrase protection. * g10/gpgv.c, g10/test-stubs.c: augment dummy agent_get_keyinfo to match new API. * g10/export.c, g10/keyedit.c, g10/keygen.c, g10/keylist.c, g10/sign.c: pass NULL to agent_get_keyinfo since we do not yet need to know whether agent is passphrase-protected. -- Signed-off-by: Daniel Kahn Gillmor --- g10/gpgv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'g10/gpgv.c') diff --git a/g10/gpgv.c b/g10/gpgv.c index 30b44220c..2aed10c2a 100644 --- a/g10/gpgv.c +++ b/g10/gpgv.c @@ -603,10 +603,12 @@ agent_probe_any_secret_key (ctrl_t ctrl, kbnode_t keyblock) } gpg_error_t -agent_get_keyinfo (ctrl_t ctrl, const char *hexkeygrip, char **r_serialno) +agent_get_keyinfo (ctrl_t ctrl, const char *hexkeygrip, + char **r_serialno, int *r_cleartext) { (void)ctrl; (void)hexkeygrip; + (void)r_cleartext; *r_serialno = NULL; return gpg_error (GPG_ERR_NO_SECKEY); } -- cgit v1.2.3