GNU bug report logs - #35682
27.0.50; Weird failure to authenticate in smtpmail

Previous Next

Package: emacs;

Reported by: Stefan Monnier <monnier <at> iro.umontreal.ca>

Date: Fri, 10 May 2019 23:28:02 UTC

Severity: normal

Tags: fixed

Merged with 26359, 31990

Found in versions 25.2, 26.1, 27.0.50

Fixed in version 27.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: 35682 <at> debbugs.gnu.org
Subject: bug#35682: 27.0.50; Weird failure to authenticate in smtpmail
Date: Sat, 11 May 2019 09:12:40 -0400
>     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 <at> 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





This bug report was last modified 5 years and 296 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.