Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I understand that there are problems with getting pinentry-curses to work with emacs (see some of the comments on http://emacswiki.org/emacs/EasyPG), and so using emacs in a terminal isn't compatible with gpg-agent because of this.

I can't use a graphical pinentry tool in this case as this is over an ssh connection to a remote machine.

However, is it possible to feed the gpg-agent the passphrase beforehand and then have emacs use this, but not to prompt for a passphrase if the agent doesn't already have this info?

What settings would allow this to work with notmuch.el and EasyPG?

Or, are there alternative methods of caching the passphrase which would achieve the same effect, but may have security problems (which is the reason gpg-agent exists in the first place)?

share|improve this question

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.