Native app has different behavior when ran inside Firefox

Damien Cassou damien at
Wed Jul 12 16:04:35 UTC 2017


I have the attached application below that just tries to decrypt a file
with gpg2. When the gpg-agent has an empty cache (I temporarily set
max-cache-ttl to 0 while testing), the application has different
behavior when ran from a terminal or from a Firefox add-on:

1- in the terminal, I get the pinentry application that asks me to enter
   the passphrase for the gpg key used to encrypt the file;

2- when launched from a Firefox web extension's browser action (Firefox
   itself being launched with `web-ext run` from the same terminal), I
   just get an error: "Public key decryption failed: Operation
   canceled. Decryption failed: No secret key". I'm never asked for my

Others have reported the exact same problem with another web-extension
and another native application (written in Go):

I checked the environment variables and they are very much similar (diff

Do you have any clue what could be different in the two environments
that could cause gpg2 to behave differently?

Damien Cassou

"Success is the ability to go from one failure to another without
losing enthusiasm." --Winston Churchill
-------------- next part --------------
A non-text attachment was scrubbed...
Name: log.diff
Type: text/x-patch
Size: 2296 bytes
Desc: not available
URL: <>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: decrypt.txt
URL: <>

More information about the Dev-addons mailing list