[Mimedefang] How to discard mail silently when it contains bad attachments

Ole Holm Nielsen Ole.H.Nielsen at fysik.dtu.dk
Fri Sep 12 15:01:01 EDT 2003


In 
http://lists.roaringpenguin.com/pipermail/mimedefang/2003-August/007540.html
it is suggested to drop .pif and .scr attachments by this code:

>      # drop all pif messages -zrd 8/19/2003
>     $drop_exts = '(pif|scr)';
>      if (re_match($entity, $drop_exts)) {
>          md_graphdefang_log("SLU dropping file $fname from $RelayAddr");
>            return action_discard();
>     }

As I discovered, that code will discard any attachments whose name
contains the substrings "scr" or "pif".  We have dropped the following
attachments erroneously today: descr.doc, manuscript.doc.  Bad, bad !

I hope the code in
http://lists.roaringpenguin.com/pipermail/mimedefang/2003-September/007768.html
works correctly.  Any comments ?

Ole Holm Nielsen
Department of Physics
Technical University of Denmark





More information about the MIMEDefang mailing list