Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 09-08-2009, 11:04 AM   #1
Registered: Jan 2005
Distribution: MythDora 3.2, RHEL 6.3
Posts: 99

Rep: Reputation: 16
gpg decrypt problems

When trying to decrypt a file I just encrypted, I get:

gpg: encrypted with 2048-bit ELG-E key, ID ABC, created 2001-11-01
gpg: decryption failed: secret key not available

I do a gpg --list-keys and gpg --list-secret-keys and can see both my public and secret keys.

The permissions appear to be ok in /home/myuser/.gnupg

This is version gpg (GnuPG) 1.2.6, RHEL 4.2.

Any other things I can try?
Old 09-08-2009, 10:01 PM   #2
Senior Member
Registered: Aug 2009
Posts: 3,790

Rep: Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653
Are you running the decryption as yourself or sudo ?

Also, is your secret key actually there ?



Last edited by kbp; 09-08-2009 at 10:03 PM.
Old 09-08-2009, 11:03 PM   #3
LQ Newbie
Registered: Sep 2009
Posts: 5

Rep: Reputation: 0

You can try from the command line GPA & (GNU Privacy Assistant), under the Keyring Editor tab you should see details: "The key has a both a public and private part." After generating your key, you should have backed up both your private and public keys to some external storage media (CD-ROM, USB), otherwise one day you will not be able to recover your files. You do not want to export your private key to a key server or share with anyone else for that matter. If both are present you should be able to run 'gpg --decrypt-files' and see a prompt for your passphrase. In some cases you can also have the passphrase cached, so you don't have to type it every time, but you should disable this option if you share your computer with anyone else.




Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
gpg / gpg-agent -- Can't connect to /root/.gnupg/S.gpg-agent jrtayloriv Linux - Security 9 06-03-2019 11:06 AM
[SOLVED] gpg: WARNING: unsafe permissions on configuration file `/home/b/.gnupg/options' gpg: widda Mandriva 9 07-30-2018 08:49 AM
GPG: Bad session key gpg between gpg on linux and gpg gui on windows XP konqi Linux - Software 1 07-21-2009 10:37 AM
Can't decrypt anything with GPG Jorophose Linux - Security 2 12-06-2007 05:57 PM
GPG Problems TatforTit Linux - Software 3 03-02-2006 11:16 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:15 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration