I have bene using
https://regex101.com <https://regex101.com/> for test and evaluation It has also helped on my composition > On May 14, 2015, at 6:48 AM, Barbara M. <barb...@rfx.it> 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 ... ;-) > > Thanks, B. >