Why is GnuPG returning "decryption failed: secret key not available"?

3

I am new to the world of GnuPG. I am attempting to decrypt a message via terminal and this is the result:

[snip]
-----END PGP MESSAGE-----
gpg: encrypted with RSA key, ID F6B86794
gpg: decryption failed: secret key not available

Is there something else I need to do with the key I created? Is there a problem elsewhere? Or am I simply going about this in the wrong manner? I am using Debian/Linux with GNOME desktop. GnuPG is pre-installed on the computer.

bbr001256

Posted 2015-11-22T19:54:38.627

Reputation: 51

Answers

3

The message indicates you're not having the private key for the OpenPGP key F6B86794 on your computer. With other words, you encrypted for a key where you don't have the public key (available).

Things to verify:

  • Did you encrypt for the right key?
  • If the message was sent to somebody else, possibly you only encrypted it for the recipient, not also for yourself. Add yourself to the list of recipients.
  • Did you create the key on another machine, user account? GnuPG maintains per-user and per-machine keyrings.

Jens Erat

Posted 2015-11-22T19:54:38.627

Reputation: 14 141

ok. i will try to add myself as recipient. the key was created on same machine, i do have the public key(seen in the list keys), and i always use the same user acct. thank you for taking time to help me. i appreciate it. – bbr001256 – 2015-11-22T23:12:27.600