[Mimedefang] Per domain filtering
Charles Gardner
charles at sterlingideas.com
Fri Nov 14 13:23:33 EST 2003
No, he's right about this. The filter_begin, filter, and filter_end are
run in the same slave. Filter_relay, filter_sender, and
filter_recipient do not necessarily run in the same slave.
As far as the per domain filtering, it's been working well for me.
Here's an excerpt of what's in filter_begin:
#***********************************************************************
if (stream_by_domain()) {
return;
}
if (lc($Domain) eq "xxxxxx.com") {
$TriggerSpamBounce = 15;
$TriggerSpamTrap = 5;
$SpamTrap = 'spamtrap at xxxxxx.com';
$TriggerSpam = 3;
} elsif (lc($Domain) eq "yyyyyy.com") {
$TriggerSpamBounce = 20;
$TriggerSpamTrap = 6;
$SpamTrap = 'spamtrap at yyyyyy.com';
$TriggerSpam = 3;
} else {
$TriggerSpamBounce = 0;
$TriggerSpamTrap = 0;
$SpamTrap = $AdminAddress;
$TriggerSpam = 0;
}
#***********************************************************************
I do AV on every message, so these values are tuned for usage with SA.
Just replace the $Trigger.... variables with a simple boolean for scan
or not. Then in filter or filter_end, use conditional logic to call the
AV & SA.
Charles
-----Original Message-----
From: Kevin A. McGrail [mailto:kmcgrail at pccc.com]
Sent: Friday, November 14, 2003 12:40 PM
To: mimedefang at lists.roaringpenguin.com
Subject: Re: [Mimedefang] Per domain filtering
Kelson & Alain,
> Also in filter_begin, before you do any scanning but after
> stream_by_domain, set a flag like $dont_filter. Then wrap each call
to a
> virus or spam scanner with "if (!$dont_filter) { ... }"
I believe this will fail because I thought that other subroutines can
actually be run by other multiplexor children. The flag as to be set in
the
sub filter routine to the best of my knowledge.
KAM
_______________________________________________
MIMEDefang mailing list
MIMEDefang at lists.roaringpenguin.com
http://lists.roaringpenguin.com/mailman/listinfo/mimedefang
More information about the MIMEDefang
mailing list