all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: 35682@debbugs.gnu.org
Subject: bug#35682: 27.0.50; Weird failure to authenticate in smtpmail
Date: Sat, 11 May 2019 09:12:40 -0400	[thread overview]
Message-ID: <jwv5zqh87n2.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <m2v9yh2t5i.fsf@gmail.com> (Robert Pluim's message of "Sat, 11 May 2019 12:16:09 +0200")

>     Stefan>     (setq send-mail-function #'smtpmail-send-it) (setq
>     Stefan> smtpmail-smtp-service 587) (setq smtpmail-smtp-server
>     Stefan> <mailserver>) (setq smtpmail-smtp-user
>     Stefan> "monnier@iro.umontreal.ca")
> Iʼd encourage 465 rather than 587, but that might not work for you.

Indeed, 465 doesn't work here.

>     Stefan> I can work around the problem with the patch below, but I
> ENOPATCH (but I can imagine what it looks like)

Duh.  See below.

> Talk to your SMTP admin, they've messed something up. 453 is basically
> 'go away, Iʼm not accepting messages'. 530 is 'go away, you haven't
> authenticated yourself'.

Yet the text they return says pretty much what you describe of 530.

> Iʼm assuming you donʼt have an authinfo entry for this user?

Indeed.

> If I remember correctly, when you do have such an entry (including
> a passwordless one) smtpmail.el will proactively authenticate, rather
> than wait for a rejection. (see smtpmail-try-auth-methods)

Shouldn't smtpmail.el also proactively authenticate when
smtpmail-smtp-user is set?


        Stefan


diff --git a/lisp/mail/smtpmail.el b/lisp/mail/smtpmail.el
index a79e3db52d..8bb8cb8fad 100644
--- a/lisp/mail/smtpmail.el
+++ b/lisp/mail/smtpmail.el
@@ -336,7 +336,11 @@ smtpmail-send-it
 	      (if (not (null smtpmail-recipient-address-list))
 		  (when (setq result
 			      (smtpmail-via-smtp
-			       smtpmail-recipient-address-list tembuf))
+			       smtpmail-recipient-address-list tembuf
+                               ;; FIXME: It looks like I need this setting
+                               ;; otherwise my SMTP server signals a 453 error
+                               ;; because I'm not authenticated.
+                               t))      ;ask-for-password
 		    (error "Sending failed: %s" result))
 		(error "Sending failed; no recipients"))
 	    (let* ((file-data






  reply	other threads:[~2019-05-11 13:12 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-10 23:26 bug#35682: 27.0.50; Weird failure to authenticate in smtpmail Stefan Monnier
2019-05-11 10:16 ` Robert Pluim
2019-05-11 13:12   ` Stefan Monnier [this message]
2019-05-11 14:47     ` Robert Pluim
2019-07-26 12:51     ` Noam Postavsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=jwv5zqh87n2.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=35682@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.