I'm trying to use keychain(1)
with my GnuPG key on Debian Testing. However, I get the following message with this command:
$ keychain --agents gpg MYPGPKEY
* keychain 2.8.2 ~ http://www.funtoo.org
* Starting gpg-agent...
* Warning: can't find MYPGPKEY; skipping
where MYPGPKEY
is my actual key.
I can check that such key exits with the following command:
$ gpg --list-keys MYPGPKEY >/dev/null 2>&1 && echo "key exists"
key exists
How can I add my gpg key with keychain?
It looks like an output parsing incompatibility between keychain 2.8.2
and gpg 2.2.4
, the two versions used in Ubuntu 18.04
I added the following to my ~/.gnupg/gpg.conf
, which fixed the issue:
keyid-format LONG
Source: https://github.com/funtoo/keychain/issues/107
I believe the problem may be associated with your gpg
and keychain
version possible incompatibility. I can see that you are using 2.8.2 version which displays this error message that 2.7.0
doesn't.
Stable version of Debian is using gnupg
1.4.18-7+deb8u3enter code here
and Testing is using 2.1.18-6
, which differ a lot.
Are you using your private key ID or your subkey ID?
My suggestion is changing the key ID provided to keychain
Reference
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With