How can I install GnuPG on my CentOS 7 system?

I want to use GnuPG alongside Thunderbird and Enigmail to manage pgp keys, as per the instructions in this link.

The problem is that the download instructions I find for linux all have to do with Debian. Here is an example.


typing which gpg resulted in /usr/bin/gpg, however, it is not clear that this is the same aspect of GnuGPG that needs to be integrated with Thunderbird and Enigmail to manage gpg keys. Before this question can be considered answered, I need to know that GnuPG is installed in a way that can run with Thunderbird and Enigmail. Thus, the answer would give instructions for checking status, and instructions for downloading if it is not properly installed yet. I imagine this might only take several lines of actual methods.

  1. install Enigmail
Thunderbird > Add-ons Menu > Enigmail
  1. If you do not already have a PGP key, generate one:
gpg --gen-key

(follow its prompts to complete the process; default values are generally fine) 3. Restart Thunderbird. Enigmail will probably auto-detect the presence of your GnuPG keychain and use it. If it does not, point it to your GnuPG dir:

Thunderbird > Enigmail > Key Management
  1. In the Key Management window, select
File > Import Keys from File

and show Enigmail to your /home/$USER/.gnupg directory. Import your key; ignore errors from Enigmail that it already knew about your key. You should now see your key listed in the Key Management window. 5. Email somebody!

  • <p>It looks like Enigmail menus have changed a bit. Go to Enigmail > Key Management.</p> <p>In Key Management window, go to File > Import Keys from File.</p><p>You gnupg folder is in /home/$USER/.gnupg, so point to that directory and Enigmail figures out the rest. I just tested it and it told me that the key already had been added to Enigmail; ignore that message. As long as you see your key listed in Key Management, you should now be ready to go. – Klaatu von Schlacker Feb 3 '15 at 23:03
  • You should not run gpg --gen-key as root. You are generating a key for yourself as a user, not as root. – Klaatu von Schlacker Feb 3 '15 at 23:07
  • I have a related question, are you willing to help me with it also? Here is the link: unix.stackexchange.com/questions/182974/… – CodeMed Feb 4 '15 at 21:11

You can just install gnupg2 (2.0.22) from thebase` repo, but chances are that it is already installed (as it was on my CentOS system).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.