[Mailman-Users] MIME type application/msexcel being saved as .binin attachment

Mark Sapiro mark at msapiro.net
Fri Oct 17 21:05:09 CEST 2008

Kimberli Tompkins wrote:
>This is the message that appears in the archive just above the
>attachment link
>A non-text attachment was scrubbed...
>Name: Lab Contact List 09-11-08.xls
>Type: application/msexcel
>Size: 31232 bytes
>Desc: not available

application/msexcel is not a registered mime type
(<http://www.iana.org/assignments/media-types/application/>). Thus,
the python function mimetypes.guess_all_extensions() does not know
what extension to assign to it and we default it to .bin.

The underlying problem is the MUA that generated the message is not
assigning the proper registered mime type application/vnd.ms-excel to
the attachment.

There are a few things you can do about it.

1) Use an MUA the gives .xls attachments the proper mime type, or

2) set


in mm_cfg.py so Scrubber will use the extension from the file name
instead of one based on the mime type and restart Mailman, or

3) add the line

application/msexcel   xls

to one of the following files

    "/etc/httpd/mime.types",                    # Mac OS X
    "/etc/httpd/conf/mime.types",               # Apache
    "/etc/apache/mime.types",                   # Apache 1
    "/etc/apache2/mime.types",                  # Apache 2
    "/usr/local/etc/httpd/conf/mime.types",     # Apache 1.2
    "/usr/local/etc/mime.types",                # Apache 1.3

and restart Mailman.

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