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.

Author r.david.murray
Recipients barry, hhm, r.david.murray, vajrasky
Date 2013-11-01.13:36:17
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1383312977.77.0.39401408042.issue19470@psf.upfronthosting.co.za>
In-reply-to
Content
I'm not sure how appropriate it is to "validate" a header using the Header object.  Header is for *composing* internationalized headers, and does no validation to speak of.  However, if you'd like to write a patch to add this check, I would probably commit it, since it is analogous to issue 5871.

However, since the security issue was already dealt with in issue 5871, this fix would be a convenience (detecting the issue earlier).  On the flip side, it would also be a behavior change, so there might be objections to backporting it.  (Do any programs use Header for things other than composing email messages and actually rely on embedded newlines?  I hope not, but you never know :)

Further, if you use the new policies available in 3.3 and 3.4 (currently provisional, but they are the Way of the Future ;), you don't ever need to use Header objects, and embedded newlines are rejected as soon as you try to assign a string containing them as a header value in a message object.
History
Date User Action Args
2013-11-01 13:36:17r.david.murraysetrecipients: + r.david.murray, barry, hhm, vajrasky
2013-11-01 13:36:17r.david.murraysetmessageid: <1383312977.77.0.39401408042.issue19470@psf.upfronthosting.co.za>
2013-11-01 13:36:17r.david.murraylinkissue19470 messages
2013-11-01 13:36:17r.david.murraycreate