[New-bugs-announce] [issue6683] smtplib authentication - try all mechanisms

Eric Shubert report at bugs.python.org
Tue Aug 11 18:17:16 CEST 2009

New submission from Eric Shubert <python at shubes.net>:

The login method in smtplib.py tries only one authentication mechanism.
There are legitimate situations where cram-md5 might fail, yet plain or
login would succeed.

RFC2554 states:
  If an AUTH command fails, the client may try another authentication
  mechanism by issuing another AUTH command.

The login method should attempt all mechanisms in preferred_auths before
returning a failure. This will make the code more robust, returning a
failure only when absolutely no authentication is possible.

messages: 91478
nosy: shubes
severity: normal
status: open
title: smtplib authentication - try all mechanisms
type: behavior
versions: Python 2.4

Python tracker <report at bugs.python.org>

More information about the New-bugs-announce mailing list