[issue15014] smtplib: add support for arbitrary auth methods

Barry A. Warsaw report at bugs.python.org
Mon Jun 22 22:39:38 CEST 2015


Barry A. Warsaw added the comment:

I believe this change broke RFC 4954's AUTH command when the optional initial-response is expected.  $4 "The AUTH Command" says:

AUTH mechanism [initial-response]
   ...
   initial-response: An optional initial client response.  If present,
   this response MUST be encoded as described in Section 4 of [BASE64]
   or contain a single character "="

It's possible that some SMTP servers only look for a string like

   AUTH PLAIN <base64-gobbledygook>

and won't issue a challenge if it's missing.  Such an example is found in the lazr.smtptest and used by the testing SMTPd in GNU Mailman.  It's possible that the servers are not standards compliant (I haven't completely groked RFC 4422), but still, since this is a backward incompatible change and breaks existing code, there should be some way of making smtplib.login() provide the initial-response, and it probably ought to be the default for backward compatibility.

----------
status: closed -> open

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue15014>
_______________________________________


More information about the Python-bugs-list mailing list