On Thu, 14 May 2015, Tom Hendrikx wrote:

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On 14-05-15 12:48, Barbara M. wrote:

I am trying to use regexp to block mails from specific domains to
specific users (and let other users receive it).

I need to merge (logical AND operator), something like:

/^From:.*\@.*domainsource.tld/      REJECT  No Unrequested mail
Please /^To:.*\@.*domaindest.tld/      REJECT  No Unrequested mail
Please

For my needs I want these rules evaluated in AND.

How can do this with a valid rules in my
/etc/postfix/header_checks? If there is a better solution ... ;-)

Header checks doesn't do AND for multiple headers, all headers get
evaluated separately. For this idea, you'd need a content filter.

So it isn't so trivial as I thought ... :-(

Within Spamassassin these kind of rules are trivial.

I use SA in default config. Never tried to customize rules, so, may be it isn't trivial for me. :-)
N.B.: I want mail rejected from Postfix not marked as spam and delivered.
If SA can do this I try it (better if someone give me some example/hints for the .cf ;-))

Thanks, B.

Reply via email to