8 messages in net.sourceforge.lists.courier-maildrop[maildropl] Re: filter attached files...
FromSent OnAttachments
joelDec 17, 2001 4:20 am 
Charlie WattsDec 17, 2001 4:58 am 
joelDec 17, 2001 11:14 am 
Charlie WattsDec 17, 2001 11:19 am 
Dan MelomedmanDec 17, 2001 11:29 am 
joelDec 17, 2001 11:39 am 
Sam VarshavchikDec 17, 2001 2:26 pm 
Dan MelomedmanDec 17, 2001 2:34 pm 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:[maildropl] Re: filter attached files i.e.: .exe, .bat ...Actions...
From:Sam Varshavchik (mrs@courier-mta.com)
Date:Dec 17, 2001 2:26:42 pm
List:net.sourceforge.lists.courier-maildrop

Dan Melomedman writes:

Use qmail-qfilter. Works great.

I recommend using a dedicated attachment scanner, instead of trying to parse attachments directly from maildrop. maildrop does not have the requisite MIME support in order to properly parse through MIME attachment files. You could probably throw something together by running reformime from maildrop, with some additional crafy scripting, which would work fine for a system with a few small mailboxes, and little mail traffic, but I don't think this would be feasible for larger systems.

Although the technical details of adding proper MIME support to maildrop are not that difficult, I can't really think of how to access MIME information from within maildrop's simple filtering language. The language will need to support arrays and structures, in order to access MIME information in a sane way.

One possibility is to have a while loop-type construct that iterates through the message's MIME hierarchy, a pre-order or in-order transversal, and on each iteration through the loop initialize common variables based on the contents of the mime headers.