Querying gpg-agent configuration options
Eric Pruitt
eric.pruitt at gmail.com
Wed Apr 27 18:02:41 CEST 2016
On Wed, Apr 27, 2016 at 11:32:21AM +0200, Werner Koch wrote:
> You may read the options from gpg-agent.conf using:
>
> gpgconf --list-options gpg-agent \
> | awk -F: '$1=="default-cache-ttl" {print $0}'
>
> which result in an output like this (line wrapped):
>
> default-cache-ttl:24:0:expire cached PINs
> after N seconds:3:3:N:600::900
>
> Here we see that the default value used by gpg-agent is 600 seconds and
> the currently configured value is 900 seconds. To get only the value,
> change the $0 in the awk command to $10. For details see the man page
> of gpgconf. gpgconf also allows to change these values; gpgme has an
> interface for that too.
Per the other messages in this thread and the original post, I want to
query the options from the gpg-agent directly. Based on some
experimentation with the configuration files and strace, gpgconf doesn't
query the information from gpg-agent, it parses the configuration files
which is not what I need. Am I missing something? If it matters, the
version of gpgconf / GPG I'm using is 2.0.14.
Thanks,
Eric
More information about the Gnupg-users
mailing list