[neomutt-users] How to encrypt emails in neomutt (in terminal only mode)?

moonmaillist at firemail.cc moonmaillist at firemail.cc
Thu May 14 17:45:54 CEST 2020


Hello everyone

I am trying to encrypt emails with neomutt, but I want to force gpg not 
to use a graphical prompt to enter passwords. The reason is 1. The 
window blocks my interaction with Keepassx (I cannot enter a password 
there) and 2. I want to use neomutt on another system, which has no GUI.

If I install pinentry-curses (for Debian based systems: sudo apt install 
pinentry-curses) and put `pinentry-mode loopback` into 
~/.gnupg/gpg.conf, gpg uses a password prompt in the terminal. It can be 
tested by creating a new key with the command: gpg --gen-key

If I try to send an encrypted email with neomutt, it says: error 
encrypting data: General error
After deleting the line in the gpg.conf the window pops up and it works.

I copied the example file from /etc/neomuttrc.d/gpg.rc and added some 
lines from https://hispagatos.org/post/neomutt-gpg-howto/ (gpg.conf is 
attached).

And I couldn't find any better tutorials than the one from 
hispagatos.org. I would really appreciate it, if someone could post a 
better tutorial with detailed instructions on how to use encryption in 
neomutt.

Thanks a lot for your help in advance.



More information about the neomutt-users mailing list