Annoying older Mailman bug with certain MIME types.

Multipurpose Internet Mail Extensions (MIME) is an Internet standard that extends the format of e-mail to support various extended formats. However with older versions of Mailman there is a serious bug which affects the archives.

MIME allows the following:

  • Text in character sets other than ASCII
  • Non-text attachments
  • Message bodies with multiple parts
  • Header information in non-ASCII character sets
  • etc.,

In emails that include MIME types included multipart/related (message parts should not be considered individually but rather as parts of an aggregate whole; see RFC 2387) and multipart/alternative(each part is an "alternative" version of similar content, each in a different format denoted by its "Content-Type" header; see RFC 2046) a problem can arises with older versions of Mailman. e.g.,


isis bin # ./version
Using Mailman version: 2.1.5

*sigh* Yes, we will upgrade (or rather decommission) that box soon.

The messages take the form in the following:

[MIME Multipart/Related (1) [Multipart/Alternative [text/plain (base64 encoded) (2)] [text/html (base64 encoded) (2)]] [image/png (1)] [image/jpg (1)] [SomeOtherType (1)] ]

Now with (1) there was a problem that archives were not being unencoded properly. This was noted as a bug some time ago and a patch was developed (technically for character sets but it works in this case as well).

The first bug was that Mailman was not decoding multpart-related material. A patch was applied to resolve this issue, which works.

The second bug however occurs when there is a multipart/alternative within a multipart/related email. This is commonly caused by text/plain and text/html which is encoded in base-64, such as by common email clients, like Microsoft Outlook.

There is no known workaround for this problem. Save yourself the time and headache and establish a plan to upgrade your old version of Mailman instead. Whilst you are waiting for the upgrade path you can decode the base64 encoded text with a handy tool developed by opinionatedgeek.