summaryrefslogtreecommitdiffstats
path: root/agent/genkey.c
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2011-04-21 15:40:48 +0200
committerWerner Koch <wk@gnupg.org>2011-04-21 15:40:48 +0200
commit4caa768f1d3388f36a6de4be9f71d916696b9e2d (patch)
tree059a687105ad2fe2b63aa5cf9205c418f1dd7f27 /agent/genkey.c
parent2011-04-20 Marcus Brinkmann <mb@g10code.com> (diff)
downloadgnupg2-4caa768f1d3388f36a6de4be9f71d916696b9e2d.tar.xz
gnupg2-4caa768f1d3388f36a6de4be9f71d916696b9e2d.zip
Add OPTION:cache-ttl-opt-preset to gpg-agent.
This option may be used to change the default ttl values use with the --preset option of GENKEY and PASSWD.
Diffstat (limited to 'agent/genkey.c')
-rw-r--r--agent/genkey.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/agent/genkey.c b/agent/genkey.c
index 30e698f77..79b99e6e5 100644
--- a/agent/genkey.c
+++ b/agent/genkey.c
@@ -432,7 +432,7 @@ agent_genkey (ctrl_t ctrl, const char *cache_nonce,
if (cache_nonce
&& !no_protection
&& !agent_put_cache (cache_nonce, CACHE_MODE_NONCE,
- passphrase, CACHE_TTL_OPT_PRESET))
+ passphrase, ctrl->cache_ttl_opt_preset))
agent_write_status (ctrl, "CACHE_NONCE", cache_nonce, NULL);
if (preset && !no_protection)
{
@@ -442,7 +442,7 @@ agent_genkey (ctrl_t ctrl, const char *cache_nonce,
{
bin2hex(grip, 20, hexgrip);
rc = agent_put_cache (hexgrip, CACHE_MODE_ANY, passphrase,
- CACHE_TTL_OPT_PRESET);
+ ctrl->cache_ttl_opt_preset);
}
}
}