[Mailman-Users] Content Filtering

Mark Sapiro mark at msapiro.net
Mon Jan 17 18:13:26 CET 2011

Ruth Indeck wrote:
>1. When I try to turn Content Filtering on, my email (an announcement of shows at a folk club, with links and some html) comes through with the html intact and a message at the top saying:
>"The message's content type was not explicitly allowed"

This message did not go to the list. It was rejected per your
filter_action = Reject setting because the message's content type was
not one of the 4 types you have listed in pass_mime_types.

Most likely, the message was an HTML only message, i.e. Content-Type:

>When I turn CF off, there is no strange message and the email comes through ok, but I worry that someone else might send an email with a bad attachment.

If you want to pass this message with content filtering on, you have to
add text/html to pass_mime_types.

Or you can set your mail client to send multipart/alternative with both
text/plain and text/html alternatives.

If you do either of the above, with collapse_alternatives and
convert_html_to_plaintext both Yes, the messager sent to the list will
be plain text only.

If you want oy allow HTML to be sent to the list, add text/html to
pass_mime_types and set both collapse_alternatives and
convert_html_to_plaintext to No.

>2. When I tried to send the same message with a pdf and a Word doc, just to test it, the message went through without any content at all -- neither the attachments nor the actual email message came through.

It is not clear what happened here. If the message were multipart/mixed
with a text/html part and, e.g., an application/pdf part, with your
settings, everything should have been removed and the message rejected
with reason "After content filtering, the message was empty".

If the message was actually delivered to the list as an empty message,
it must have contained a, possibly blank, text/plain part.

>Here are the settings I am using:

With these settings, you need to post plain text or
multipart/alternative with a plain text part. If you want to allow
HTML, add text/html to pass_mime_types, and set both
collapse_alternatives and convert_html_to_plaintext to No, or if you
want to convert the HTML to plain text, leave them Yes.

Mark Sapiro <mark at msapiro.net>        The highway is for gamblers,
San Francisco Bay Area, California    better use your sense - B. Dylan

More information about the Mailman-Users mailing list