0

my current mu4e setup uses MSMTP utility to send out emails. Unfortunately if I want to use queues I have to use smtpmail.el which requires me either to (1) save my password in cleartext in .authinfo, (2) enter my password every time, (3) enter my PGP passphrase when using .authinfo.gpg. None of these solutions is very convenient.

Is there a way to convince smtpmail.el to retrieve my password from an Emacs lisp function, possibly without storing it for too long? I have an Emacs lisp function that extract the password from the keychain, so that would be ideal.

  • 1
    You don't have to use auth-source's authinfo backend. There's a 'Secret Service Api' one that integrates with the Gnome Keyring and the KDE Wallet. See <gnu.org/software/emacs/manual/html_node/auth/…> – rpluim Apr 8 at 13:43
  • Thank you. It seems that this solution is only for GNU/Linux, but I need a solution that works on macOS too. I see that there are auth-sources types for macOS key chain. That could be an option. – MassimoLauria Apr 8 at 14:18
  • Make use of gpg-agent. You can use it to avoid entering the passphrase each time from your elisp function or instruct msmtp to extract the password from a command. – Muihlinn Apr 16 at 6:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.