LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise
User Name
Password
Linux - Enterprise This forum is for all items relating to using Linux in the Enterprise.

Notices


Reply
  Search this Thread
Old 05-17-2022, 01:57 PM   #1
lamoul
LQ Newbie
 
Registered: Aug 2009
Posts: 5

Rep: Reputation: 0
gpg ecrypt / decrypt on Redhat 8


Hi,

i am upgrading my redhat 6 to redhat 8. On redhat 6 i was using this code to decrypt the gpg file now with same code do not work on redhat 8.

Redhat 6: NO ISSUE
cat /etc/redhat-release
Red Hat Enterprise Linux Server release 6.10 (Santiago)
gpg --version
gpg (GnuPG) 2.0.14

command to decrypt on redhat
/usr/bin/gpg2 --armor --batch --passphrase-file $HOME/.gnupg/passphrase.asc \
--status-file $HOME/FILES/new-test-file.log \
--output $HOME/NEW-KEY-FILES/test_key_001.txt \
--decrypt $HOME/NEW-KEY-FILES/test_key_001.txt.pgp

Redhat 8: ISSUE
Red Hat Enterprise Linux release 8.5 (Ootpa)
gpg --version
gpg (GnuPG) 2.2.20

command to decrypt

/usr/bin/gpg2 --armor --batch --pinentry-mode loopback --passphrase-file $HOME/.gnupg/passphrase.asc \
--status-file $HOME/FILES/new-test-file.log \
--output $HOME/NEW-KEY-FILES/test_key_001.txt \
--decrypt $HOME/NEW-KEY-FILES/test_key_001.txt.pgp

gpg: encrypted with 2048-bit RSA key, ID keyxxxx, created 2022-03-24
"key (Decrypt files) "
gpg: handle plaintext failed: General error

Anyone is having this issue please help.

Thank you very much!
 
Old 05-18-2022, 10:35 AM   #2
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,635

Rep: Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965
Quote:
Originally Posted by lamoul View Post
Hi,
i am upgrading my redhat 6 to redhat 8. On redhat 6 i was using this code to decrypt the gpg file now with same code do not work on redhat 8.

Redhat 6: NO ISSUE
cat /etc/redhat-release
Red Hat Enterprise Linux Server release 6.10 (Santiago)
gpg --version
gpg (GnuPG) 2.0.14

command to decrypt on redhat
/usr/bin/gpg2 --armor --batch --passphrase-file $HOME/.gnupg/passphrase.asc --status-file $HOME/FILES/new-test-file.log --output $HOME/NEW-KEY-FILES/test_key_001.txt --decrypt $HOME/NEW-KEY-FILES/test_key_001.txt.pgp

Redhat 8: ISSUE
Red Hat Enterprise Linux release 8.5 (Ootpa)
gpg --version
gpg (GnuPG) 2.2.20

command to decrypt
/usr/bin/gpg2 --armor --batch --pinentry-mode loopback --passphrase-file $HOME/.gnupg/passphrase.asc --status-file $HOME/FILES/new-test-file.log --output $HOME/NEW-KEY-FILES/test_key_001.txt --decrypt $HOME/NEW-KEY-FILES/test_key_001.txt.pgp

gpg: encrypted with 2048-bit RSA key, ID keyxxxx, created 2022-03-24 "key (Decrypt files) "
gpg: handle plaintext failed: General error
Your two commands don't match, and you don't say what happens if you run the first command for RH6 on the RH8 server. Also, in doing a small bit of research, your error indicates some sort of file-name problem. The gpg program doesn't expand variables...have you tried putting in the entire filename, rather than just "$HOME/..."??

Also, have you contacted Red Hat support? You're using RHEL6 and RHEL8...you're PAYING for support, right??
 
  


Reply



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
mutt unable to decrypt emails "Could not decrypt PGP message" frddbbbl Linux - Software 3 07-25-2019 10:48 AM
gpg / gpg-agent -- Can't connect to /root/.gnupg/S.gpg-agent jrtayloriv Linux - Security 9 06-03-2019 10:06 AM
gpg decrypt problems bic Linux - Newbie 2 09-08-2009 10:03 PM
GPG: Bad session key gpg between gpg on linux and gpg gui on windows XP konqi Linux - Software 1 07-21-2009 09:37 AM
Can't decrypt anything with GPG Jorophose Linux - Security 2 12-06-2007 04:57 PM

LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise

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

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