I'm facing a similar problem to the one described here. However, the error I receive when I try to send a email from mu4e is:
smtpmail-send-it: Sending failed: 530-5.7.0 Authentication Required
Here is my configuration section in the config.el
file of Doom Emacs (following this post by djcb):
(require 'smtpmail)
(setq message-send-mail-function 'smtpmail-send-it
starttls-use-gnutls t
smtpmail-stream-type 'starttls
smtpmail-starttls-credentials '(("smtp.gmail.com" 587 nil nil))
;; smtpmail-auth-credentials (expand-file-name "~/.authinfo.gpg")
smtpmail-smtp-user "[email protected]"
smtpmail-default-smtp-server "smtp.gmail.com"
smtpmail-smtp-server "smtp.gmail.com"
smtpmail-smtp-service 587)
I read here that the variable smtpmail-auth-credentials
is no longer used, and that .authinfo
is searched automatically. So I placed my authentication info in .authinfo.gpg
. The content of the file is:
machine smtp.gmail.com login myuser@server password "app-pass" port 587
where app-pass is the 16 character app specific password that I generated through Gmail 2FA settings.
I know that smtpmail is accessing the .authinfo.gpg
file because I'm asked for the password to decrypt the file. However, I always end up receiving the error message above.
Any clues? Thanks