[Mimedefang] Bypass MD+SA filtering by domain name

David F. Skoll dfs at roaringpenguin.com
Thu Oct 14 16:36:24 EDT 2004


On Thu, 14 Oct 2004, Liang, Warren wrote:

>     if (stream_by_domain()) {
> 	return;
>     }

That's fine.

>     if (canonicalize_email($Domain) eq 'eastcoast.com') {
>             return("ACCEPT_AND_NO_MORE_FILTERING", "ok");
>    }

That won't work; the ACCEPT_AND_NO_MORE_FILTERING trick only works
from filter_relay, filter_sender and filter_recipient.  Here, you have
to put the following code at the beginning of ALL 4 of the functions
filter_begin, filter, filter_multipart and filter_end:

if (canonicalize_email($Domain) eq 'eastcoast.com') {
    return;
}

However, this begs the question:  Why not just use a different MX host
for eastcoast.com?  (You could probably run it on the same box with
a different instance of Sendmail bound to a different IP address, but
the book-keeping gets tricky.)

Regards,

David.



More information about the MIMEDefang mailing list