Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
gpg: public key decryption failed: No pinentry
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Abbott
n00b
n00b


Joined: 23 Mar 2020
Posts: 7

PostPosted: Tue Feb 23, 2021 2:47 am    Post subject: gpg: public key decryption failed: No pinentry Reply with quote

I updated my laptop on Saturday and now I am having problems with pinentry. If I try to use gpg, I get the error in the Subject:
Code:
aquarius% gpg -d ~/.password-store/gentoo.org/Abbott.gpg
gpg: encrypted with 4096-bit RSA key, ID XXXXXXX, created yyyy-mm-dd
      "xxxxx (gpg2 key for pass) <xxxxx@gmail.com>"
gpg: public key decryption failed: No pinentry
gpg: decryption failed: No secret key
aquarius%

I can see that pinentry-gnome3 is installed in /usr/bin/ and selected with eselect, I can run pinentry and get "OK Pleased to meet you", and I have tried the solutions listed in other threads I found searching the forums here and here. What is wrong with pinentry?
Back to top
View user's profile Send private message
figueroa
Veteran
Veteran


Joined: 14 Aug 2005
Posts: 1204
Location: Edge of the Marsh USA

PostPosted: Tue Feb 23, 2021 3:07 am    Post subject: Reply with quote

Is "gpg: encrypted with 4096-bit RSA key" what you are expecting. I don't use a key. I encrypt with AES256 and don't see anything about a key.

For troubleshooting pinentry, try switching to another interface, curses or tty.
_________________
Andy Figueroa
andy@andyfigueroa.net Working with Unix since 1983.
Automate and Test Your Backups
Back to top
View user's profile Send private message
figueroa
Veteran
Veteran


Joined: 14 Aug 2005
Posts: 1204
Location: Edge of the Marsh USA

PostPosted: Tue Feb 23, 2021 3:15 am    Post subject: Reply with quote

You may want to doublecheck that the pinentry symlink is really set how you intend.
Code:
$ ls /usr/bin/pine* -l
lrwxrwxrwx 1 root root     15 Feb 25  2019 /usr/bin/pinentry -> pinentry-curses*
-rwxr-xr-x 1 root root  68944 Jan 25 13:34 /usr/bin/pinentry-curses*
-rwxr-xr-x 1 root root  81520 Jan 25 13:34 /usr/bin/pinentry-gnome3*
-rwxr-xr-x 1 root root 123408 Jan 25 13:34 /usr/bin/pinentry-qt*
lrwxrwxrwx 1 root root     11 Jan 25 13:34 /usr/bin/pinentry-qt5 -> pinentry-qt*
-rwxr-xr-x 1 root root  64616 Jan 25 13:34 /usr/bin/pinentry-tty*

_________________
Andy Figueroa
andy@andyfigueroa.net Working with Unix since 1983.
Automate and Test Your Backups
Back to top
View user's profile Send private message
VTimofeenko
n00b
n00b


Joined: 04 Feb 2021
Posts: 14

PostPosted: Tue Feb 23, 2021 4:09 am    Post subject: Reply with quote

Double-check that the pinentry specified in gpg-agent.conf is one of the installed ones. TK pinentry was recently dropped.

Is dbus actually running? Can you echo $DBUS_SESSION_BUS_ADDRESS in the same shell where gpg fails?

Also, ".password-store" hints at usage of app-admin/pass. Did you use the default keyring when initializing the password store? You can override GPG_HOME when creating the password store.
Back to top
View user's profile Send private message
Abbott
n00b
n00b


Joined: 23 Mar 2020
Posts: 7

PostPosted: Tue Feb 23, 2021 5:35 am    Post subject: Reply with quote

VTimofeenko wrote:
Double-check that the pinentry specified in gpg-agent.conf is one of the installed ones. TK pinentry was recently dropped.

This was my problem. My ~/.gnupg/gpg-agent.conf had
Code:
pinentry-program /usr/bin/pinentry-gtk-2

which must have been removed in my last update and --depclean. Changing it to /usr/bin/pinentry-gnome3 has fixed everything. Thank you for the help
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum