Skip to content

Defend against certain malformed messages.

username-removed-107958 requested to merge msapiro/mailman:as_string into master

Fixes #406 Fixes #256 (closed)

Accommodate https://bugs.python.org/issue27321 by overriding as_string() in mailman.email.message.Message to catch the KeyError, get the message as_bytes() and convert it to a string. This obviates !197 (closed) as a fix for #256 (closed) so that is reverted.

Also fix mailman.mta.connection.Connection.sendmail to ensure msgtext is pure ascii.

Merge request reports