gpg-agent only works when started in terminal

Antony Prince antony at blazrsoft.com
Thu Sep 8 00:44:34 CEST 2016


I know this has got to be something simple. When invoking gpg2 normally
to decrypt, I get:

gpg: encrypted with 4096-bit RSA key, ID 0E98CD22ADB13E99, created
2015-05-06
      "Antony Prince <antony AT blazrsoft.com>"
gpg: public key decryption failed: No pinentry
gpg: decryption failed: No secret key

I have pinentry-program set properly in ~/.gnupg/gpg-agent.conf.

If I do:

killall gpg-agent
gpg-agent --daemon /bin/sh

The pinentry appears as it should and all is fine.
I also have:

GPG_TTY=$(tty)
export GPG_TTY

set in ~/.bashrc as I saw that mentioned somewhere as well.

agent info:
gpg-agent[14849]: gpg-agent (GnuPG) 2.1.15 started

gpg info:
antony at 050415:~$ gpg2 --version
gpg (GnuPG) 2.1.15
libgcrypt 1.7.3
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<https://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Home: /home/antony/.gnupg
Supported algorithms:
Pubkey: RSA, ELG, DSA, ECDH, ECDSA, EDDSA
Cipher: IDEA, 3DES, CAST5, BLOWFISH, AES, AES192, AES256, TWOFISH,
        CAMELLIA128, CAMELLIA192, CAMELLIA256
Hash: SHA1, RIPEMD160, SHA256, SHA384, SHA512, SHA224
Compression: Uncompressed, ZIP, ZLIB, BZIP2

If anyone has any ideas, I'm all for them.

-- 

Antony Prince

Key ID: 0xAF3D4087301B1B19
Fingerprint: 591F F17F 7A4A A8D0 F659  C482 AF3D 4087 301B 1B19
URL:
http://pool.sks-keyservers.net/pks/lookup?op=get&search=0xAF3D4087301B1B19

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: OpenPGP digital signature
URL: </pipermail/attachments/20160907/53ce945d/attachment.sig>


More information about the Gnupg-users mailing list