atom feed4 messages in com.roaringpenguin.lists.mimedefang[Mimedefang] Redirect spam to a spam ...
FromSent OnAttachments
Laurent BOULEAUJan 6, 2004 10:11 am 
Renaud PASCALJan 6, 2004 10:36 am 
Kevin A. McGrailJan 6, 2004 12:31 pm 
Renaud PASCALJan 6, 2004 12:44 pm 
Subject:[Mimedefang] Redirect spam to a spam maildrop by score
From:Kevin A. McGrail (kmcg@pccc.com)
Date:Jan 6, 2004 12:31:51 pm
List:com.roaringpenguin.lists.mimedefang

That solution below will certainly work but I believe it's a "better" solution not to use procmail. Assuming you are not using the MASQUERADE_AS in your sendmail.mc, the following should work fine though I've never done the bounce part so someone else please comment about that:

Inside your loop for "if ($hits >= $req) { ", add this at the bottom

if ($hits >= 20) { #bounce anything with a score over 20 -- UNTESTED action_bounce("Spam found in mail - rejected"); }elsif ($hits >= 10) { #FROM THE MIMEDEFANG FAQ # Add a header with original recipients, just for info action_add_header("X-Orig-Rcpts", join(", ", @Recipients));

# Remove original recipients foreach $recip (@Recipients) { delete_recipient($recip); }

# Send to spam address add_recipient('spam@mydomain.net'); }

Regards, KAM