Hi, > Other option also would be to use antispam solutions and write such rules > there, they allow much more complex logic and if your intention to prevent > spam - antispam system that has sane defaults is good choice. Postfix can > work with any milter compatible antispam like Rspamd or SpamAssassin. I > personally would recommend look at Rspamd as it HA, designed better than > SA, has much more functions. > Yes, I'm already using SA with amavisd and have blocklist rules (and meta rules with more flexibility), but I feel like doing it at the SMTP level would be easier, and also avoid quarantining the junk when it should just be rejected.
For multi-criteria rules use an smtpd_milters milter-regex plugin. >> >> Example: >> >> /etc/postfix/main.cf: >> smtpd_milters = inet:127.0.0.1:9999 >> >> /etc/mail/milter-regex.conf: >> reject >> header /From/ /^user@baddom\.tld$/i and envrcpt /@example\.com$/i >> > It looks like this is the place to start? https://github.com/milter-regex/milter-regex/tree/main Can I ask usage questions about this plugin here? Thanks, Alex
_______________________________________________ Postfix-users mailing list -- postfix-users@postfix.org To unsubscribe send an email to postfix-users-le...@postfix.org