Japanatron Logo

My domain name registrar offers email aliases and forwarding; however, this feature causes my mail server's SPF checks to fail because the registrar's mail relay sends on behalf of the originating server.  I fixed it by white-listing the registrar's mail relay IP block in SpamAssassin.

1. Add a "trusted_networks" line to the SpamAssassin config.  As of Zimbra 8.5 and later, the reported location to customize SpamAssassin is here:
/opt/zimbra/data/spamassassin/localrules

I refer to this article for the latest location for customizing SpamAssassin: https://wiki.zimbra.com/wiki/Anti-spam_Strategies#Customizing_SpamAssassin

Edit the file in here called local.cf and add your "trusted_networks" (example below).  You'll notice this file contains a comment at that top that says something like, "This is the place to customize SpamAssassin..."  I've also seen a file called user_prefs.cf being used instead.  To be honest I don't think the file name matters much because I believe SpamAssassin reads all the cf files in this folder.

# TRUST REGISTRAR RELAY
trusted_networks 123.45.6/24


2. Restart Zimbra.
su - zimbra
zmcontrol restart

FURTHER READING
http://spamassassin.apache.org/full/3.4.x/doc/Mail_SpamAssassin_Conf.html

Related Articles

Nginx - How to Block or Redire...

I've been figuring out how to block or redirect web traffic in Nginx based on the country geoIP. NOTES* You need the package nginx-extras for this because this...

Toshiba 37Z2000 TV - Sensitive...

My Toshiba 37Z2000 TV has a cool feature that allows me to record TV over my network to a CIFS (aka Samba) file share on my FreeNAS server.  Unfortunately, howe...

Joomla Running on Nginx and Ub...

What follows is an outline I compiled while researching how to tighten security on a Nginx web server. NOTE 1: Ubuntu 14.04 LTS was used for this. NOTE 2: This ...

Ubuntu 22.04 Nginx Build Outli...

I re-built my LEMP web-server fresh on Ubuntu 22.04 and learned some things along the way. This is my base build outline mostly created for my own notes. INS...