I've solved similar problem using header_checks
1. Edit your /etc/postfix/main.cf
Include something like
header_checks = pcre:/etc/postfix/header_checks.pcre
NB. Must reload postfix after editing /etc/postfix/main.cf
2. Edit your /etc/postfix/header_checks.pcre
The format can be as...
Now that the MailChimp problem has been solved, we're moved on.
Since we don't want to receive any emails from correspondents in Russia or Ukraine,
the following lines in header_checks.pcre are stopping a quantity of spam being processed by our email server.
/^From:.*\.ru>?$/i REJECT...
Well, after using a nice file of header_checks for a coupla weeks, We're getting this job done.
Many lines in header_checks.pcre like this one :
/^From:.*@linkedin\.com/i REJECT SPAM is rejected. Sender address is blacklisted.
For the most persistent spammers, our perimeter firewall now...
For the moment we're staying within postfix, since I have little experience with SA.
Also, I like giving the unwanted sender/s a specially crafted REJECT message which is intended to cause them confusion. It appears to work.
There's some good and relevant info at the bottom of this page...
We use a different technique to reject emails spoofing our domain/s. Greylisting.
It is very successful.
On CentOS the package is postgrey.
Simply, many spammers make up random usernames, and typically only make a single attempt to deliver their payloads.
So those emails are never accepted by...
Yes, I've been contemplating something similar.
Create an email folder/file called "Blocked".
Move emails to the Blocked folder/file as desired.
Nightly script to parse the users' Blocked emails and update the postfix header_checks file as needed to include REJECT.
Since we only use webmail, and...
This is another good thread for postifx on CentOS.
https://wiki.centos.org/HowTos/postfix
See especially the part/s about ensuring you're not an open relay.
HTH
Chris, thanks for your reply.
Perhaps "obfiscated" is a better description for Mailchimp's smptd FROM headers.
Meanwhile, I'm redefining our problem, and hoping to stay within the postfix framework to achieve a satisfactory rejection outcome.
We have a manageable number of senders who (despite...
Sadly, it seems the smptd_recipient_restrictions are not sufficient to block selected junk spewing out from Mailchimp's servers.
I'm not surprised, since Mailchimp has significant resources to ensure their messages are not easily blocked.
From the mail logs, it looks like Mailchimp is forging...
Chris
I've blown a few years of dust off some good old texts.
Postfix (2001) by Richard Blum ; and
The Book of Postfix (2005) by Ralf Hildenbrandt and Patrick Koetter
Yes, I have some dead-tree versions in my library.
Also...
Chris
Thanks for the great explanation. I couldn't find that anywhere else. I give you a star.
I agree its easy, almost obvious, when you know how/why.
I'm not a complete idiot. There's still a few pieces missing.
[SOLVED]
Looks like my PBKAC
smtpd_sender_restrictions = check_sender_access hash:/etc/postfix/sender_access
I had incorrectly included the above instruction within section smptd_sender_restrictions =
Now moved to section smptd_recipient_restrictions = and appears working as intended.
This...
Hi forum
We like and have been using Postfix in our small business for many years.
We have a small~ish list of sender domains that we reject using the usual details in /etc/postfix/sender_access and the following line in /etc/postfix/main.cf
smtpd_sender_restrictions = check_sender_access...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.