------------------------------------------------------------
revno: 1138
committer: Mark Sapiro <[email protected]>
branch nick: 2.2
timestamp: Thu 2011-01-13 16:57:05 -0800
message:
- Fixed a bug that could erroneously handle posts from addresses in
*_these_nonmembers and send held/rejected notices to bogus addresses when
The From or other sender header is RFC 2047 encoded. Bug #702516.
modified:
Mailman/Message.py
NEWS
--
lp:mailman/2.2
https://code.launchpad.net/~mailman-coders/mailman/2.2
Your team Mailman Checkins is subscribed to branch lp:mailman/2.2.
To unsubscribe from this branch go to
https://code.launchpad.net/~mailman-coders/mailman/2.2/+edit-subscription
=== modified file 'Mailman/Message.py'
--- Mailman/Message.py 2009-08-01 23:12:35 +0000
+++ Mailman/Message.py 2011-01-14 00:57:05 +0000
@@ -1,4 +1,4 @@
-# Copyright (C) 1998-2009 by the Free Software Foundation, Inc.
+# Copyright (C) 1998-2011 by the Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
@@ -149,9 +149,11 @@
if not fieldval:
continue
# Work around bug in email 2.5.8 (and ?) involving getaddresses()
- # from multi-line header values. Note that cset='us-ascii' is OK
- # since the address itself can't be RFC 2047 encoded.
- fieldval = Utils.oneline(fieldval, 'us-ascii')
+ # from multi-line header values.
+ # Don't use Utils.oneline() here because the header must not be
+ # decoded before parsing since the decoded header may contain
+ # an unquoted comma or other delimiter in a real name.
+ fieldval = ''.join(fieldval.splitlines())
addrs = email.Utils.getaddresses([fieldval])
try:
realname, address = addrs[0]
@@ -207,7 +209,7 @@
if fieldvals:
# See comment above in get_sender() regarding
# getaddresses() and multi-line headers
- fieldvals = [Utils.oneline(fv, 'us-ascii')
+ fieldvals = [''.join(fv.splitlines())
for fv in fieldvals]
pairs.extend(email.Utils.getaddresses(fieldvals))
authors = []
=== modified file 'NEWS'
--- NEWS 2011-01-04 23:44:56 +0000
+++ NEWS 2011-01-14 00:57:05 +0000
@@ -83,6 +83,10 @@
Bug Fixes and other patches
+ - Fixed a bug that could erroneously handle posts from addresses in
+ *_these_nonmembers and send held/rejected notices to bogus addresses when
+ The From or other sender header is RFC 2047 encoded. Bug #702516.
+
- Updated contrib/mm-handler-2.1.10 to better handle lists with names that
look like admin addresses. Bug #697161.
_______________________________________________
Mailman-checkins mailing list
[email protected]
Unsubscribe:
http://mail.python.org/mailman/options/mailman-checkins/archive%40jab.org