MX backup server and Easy Spam Fighter problem

elvch01

Verified User
Joined
Apr 19, 2016
Messages
5
Hi

I have been offered the use of a 2nd server as an MX backup and during testing I have found the following issue:

When I forward certain emails from the backup MX to my DirectAdmin server, I get a 550 error from the DirectAdmin Server due to an SPF failure. This is understandable because the SPF for the original domain of my test emails specifies that mail must come from specific IP addresses and of course my MX backup is not one of them. One way of avoiding this is to add in the IP address to the MX backup server into /etc/virtual/whitelist_hosts_ip - but I would like to have all the other benefits of the Easy Spam Fighter add on which I believe is the cause of the 550 rejection

In /etc/exim.easy_spam_fighter/check_mail.conf , we have the following code
Code:
drop
    condition = ${if !eq{EASY_SPF_SOFT_FAIL}{0}}
    spf = fail
    message = SPF: $sender_host_address is not allowed to send mail from $sender_address_domain: $spf_smtp_comment
which I believe is the cause of the issue. How do I modify this code to skip the EASY_SPF_SOFT_FAIL test for messages coming from the MX backup server?

Thanks In Advance
Chris
 
I think you're going to run into a secondary issue, if you get past your first issue.

When SPF becomes un-aligned (when you forward it) it will also break DMARC, if that user has a DMARC Policy set that will cause a rejection as well.

You can read about: Email Identifiers

It's best just to whitelist all emails from your server, unless you're just forwarding everything.
 
Back
Top