Having read postfix.org/regexp_table.5.html, I'm experimenting to stop
junk mail to common system accounts with
check_recipient_access regexp:/etc/postfix/reject_by_recipient_regexp
and trying to learn how to craft regexp's. I've tried many iterations
similar to:
/^To: man@/ REJECT or /^To: m...@mydomain\.tld/ REJECT
I issue postfix reload after edits but the syntax is wrong so my test
message still queues for delivery.
May 12 16:29:45 mail postfix/smtpd[14294]: connect from
outbound.mydomain.tld[x.x.x.x]
May 12 16:29:47 mail postfix/smtpd[14294]: F0E792BC36:
client=outbound.mydomain.tld[x.x.x.x]
May 12 16:29:48 mail postfix/cleanup[14298]: F0E792BC36:
message-id=<51d9d6bfdd2b4143825eb048e4266fbe08422...@outbound.mydomain.tld>
May 12 16:29:48 mail postfix/qmgr[14170]: F0E792BC36:
from=<m...@mydomain.tld>, size=3744, nrcpt=1 (queue active)
May 12 16:29:48 mail postfix/local[14299]: F0E792BC36:
to=<m...@mydomain.tld>, relay=local, delay=0.35, delays=0.32/0.01/0/0.02,
dsn=2.0.0, status=sent (delivered to mailbox)
May 12 16:29:48 mail postfix/qmgr[14170]: F0E792BC36: removed
May 12 16:29:48 mail postfix/smtpd[14294]: disconnect from
outbound.mydomain.tld[x.x.x.x]
What should proper syntax look like?