[Mailman-Developers] SCRUBBER Question

Robby Griffin rmg at terc.edu
Fri Sep 24 23:42:47 CEST 2004


On Friday, Sep 24, 2004, at 16:55 US/Eastern, Mark Sapiro wrote:

> You might try putting a .htaccess file in archives/private/listname or
> in archives/private/listname/attachments with a
>
>   AddType application/msword bin
>
> directive in it. Depending on your web server and browser, this may
> work, but if it does it will then try to open any .bin attachment with
> msword which will be a problem if you have any non-msword attachments
> that get saved with "bin" extensions.

This is pretty lame. I run Mailman in an environment where most of the 
users use Lotus Notes on Macs, and in our case Mailman converted the 
vast majority of their attachments to .bin or .obj because Notes sent 
most things as application/octet-stream. PDF file? .bin. Excel file? 
.bin. Word doc? .bin. Argh. Users can NOT figure out how to open these 
files (or even what application they were supposed to have been 
openable in) after getting them from the archives. Most of them had 
Stuffit Expander launch automatically (on the .bin file, duhr) and were 
generally confused.

I operate under the assumption that Apache knows more about MIME types 
and extension mappings than Mailman does, so I hacked my Scrubber.py to 
avoid ever altering the extensions of attachments. Note that if you do 
this you have to be careful not to let the webserver do any server-side 
processing on any files in the archiver attachment area. It's also 
useful to make the default type for files of unrecognized extension be 
application/octet-stream so that they don't display in the browser -- 
this is done in .htaccess for public archives and in private.py for 
private archives.

I'll come up with a patch if anyone wants it, but seriously, YMMV, a 
lot.

	--Robby



More information about the Mailman-Developers mailing list