[Mimedefang] Stream-by-domain-filter example filter

Anthony Giggins AGiggins at synergyit.com.au
Thu Apr 18 19:42:37 EDT 2002


In the stream-by-domain example

sub filter {
    my($entity, $fname, $ext, $type) = @_;

    if ($Domain eq "abc.com") {
        # Filter actions for abc.com
    } elsif ($Domain eq "xyz.com") {
        # Filter actions for xyz.com
    } else {
        # Default filter actions
    }
}


it has default filter actions at the bottom but these don't get run if
domain is matched above. I assume the domain matches only cover incoming
emails and the default filter covers outgoing emails?

Would I be correct in saying the any filters you wish to be global are to be
run before or after the Domain matches? And if so which would be more
correct before or after?





More information about the MIMEDefang mailing list