]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-143921: Narrow the control character check in imaplib commands (GH-153067)
authorSerhiy Storchaka <storchaka@gmail.com>
Sun, 5 Jul 2026 15:25:36 +0000 (18:25 +0300)
committerGitHub <noreply@github.com>
Sun, 5 Jul 2026 15:25:36 +0000 (18:25 +0300)
commitd0921efb665aff26b378f495e5ff84f7e3fe649d
tree13ab01a2d3f8a69afa13efa55613179b9162584f
parent74a2438bf783077cf49460ed0fed8853675fb103
gh-143921: Narrow the control character check in imaplib commands (GH-153067)

Only NUL, CR and LF are rejected now.  Other control characters are
valid in quoted strings and can occur in mailbox names returned by
the server, so they are now accepted and sent quoted.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Lib/imaplib.py
Lib/test/test_imaplib.py
Misc/NEWS.d/next/Library/2026-07-05-10-24-30.gh-issue-143921.wQx3Tn.rst [new file with mode: 0644]