[pass] gpg: cannot open `/dev/tty': Device not configured

Mateusz Lenik mlen at mlen.pl
Mon Sep 21 14:42:43 CEST 2015


On Mon, Sep 21, 2015 at 12:14:55PM +0200, Ivan Pedersen wrote:
> Hi,
> 
> I wanted to start using the OS X integration but I can’t get it to work. I use the script from here (Thanks Steffen) http://git.zx2c4.com/password-store/tree/contrib/pass.applescript <http://git.zx2c4.com/password-store/tree/contrib/pass.applescript> and have added the notification and shortcut to the service. But whenever I try to fetch a key i get this error message: "gpg: cannot open `/dev/tty': Device not configured”.
> 
> 
> 
> I only get it when trying to get a key that actually exists in the store, otherwise i get "Error: root is not in the password store.” for example.
> 
> Anyone here had this problem or can help me with it?
> 
> /Ivan
> 
> 

First off, did you install GPG via homebrew or from gpgtools.org?

I suspect you have used the former and in this case I'd suggest 
installing pinentry-mac formula and configuring GPG to use it.


Broader explanation: GPG by default uses pinentry that came with it.  
This program requires a tty to be able to read the password for the key 
in, while the script you linked runs pass without terminal. In this case 
pinentry doesn't know which tty to use and tries the default one.
That fails, so the decryption fails too.

-- 
Mateusz Lenik
PGP B865 E86A D36C 11A5 C1F8  C1D9 AAD4 CEC9 6B94 92C4
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.zx2c4.com/pipermail/password-store/attachments/20150921/a5bf1f0c/attachment.asc>


More information about the Password-Store mailing list