This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: Add IMAP4.login_plain to imaplib
Type: enhancement Stage: patch review
Components: email, Library (Lib) Versions:
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: barry, przemub, r.david.murray
Priority: normal Keywords: patch

Created on 2021-11-04 00:29 by przemub, last changed 2022-04-11 14:59 by admin.

File name Uploaded Description Edit
0107-Add-imaplib.IMAP4.login_plain.patch przemub, 2021-11-04 00:29 Patch
Pull Requests
URL Status Linked Edit
PR 29398 open przemub, 2021-11-04 00:44
Messages (1)
msg405659 - (view) Author: Prem Buczkowski (przemub) * Date: 2021-11-04 00:29
Hi everyone and nice to meet you!

I would like to propose adding a method login_plain to Python IMAP4 standard library client.

Currently, one can use login, login_cram_md5 or add their own authentication method using authenticate. While login works great for plain text authentication for English users, it does not support characters out of ASCII, causing errors for users with non-ASCII passwords. 

I personally hit that with radicale-imap. It has been reported in issue34577, and its SMTP counterpart in issue29750.

RFC6855 recommends using AUTHENTICATE for such cases, and so this patch adds login_plain in a manner similar to login_cram_md5. Adding this to a standard library will improve the experience for non-English users not only when programming but also when using other programs written in Python. AUTHENTICATE PLAIN is on by default in Dovecot and most e-mail providers, like Gmail and Outlook, making it more common than, already supported, AUTHENTICATE CRAM-MD5.

Since this is my first patch, let me know if I could change something up - I did my best to RTFM!
Date User Action Args
2022-04-11 14:59:52adminsetgithub: 89869
2021-11-04 00:44:53przemubsetstage: patch review
pull_requests: + pull_request27656
2021-11-04 00:30:19przemubsettype: enhancement
2021-11-04 00:29:59przemubcreate