[issue43949] binascii.Error raised in smtplib when initial_response_ok=False

Pandu E POLUAN report at bugs.python.org
Thu May 6 02:22:34 EDT 2021


Pandu E POLUAN <pepoluan at gmail.com> added the comment:

Technically, that is not the fault of smtplib.SMTP

The standard for SMTP AUTH specifies that characters following "334 " MUST be Base64 encoded.

See https://tools.ietf.org/html/rfc4954#page-4 , 3rd paragraph:

> A server challenge is sent as a 334 reply with the text part
> containing the [BASE64] encoded string supplied by the SASL
> mechanism.  This challenge MUST NOT contain any text other
> than the BASE64 encoded challenge.

Servers that send non-BASE64-encoded text after "334 " IMO is violating the standards.

----------
nosy: +pepoluan

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue43949>
_______________________________________


More information about the Python-bugs-list mailing list