Sophos UTM: Decommissioning of obsolete URL categorization services CFFS.Click here for important info.

M365, Email Security Mailflow, Outbound SPF failure

Hi, we're fairly new with M365 and Sophos Email Security set up with Mailflow and working fine.

Today I had a customer reach out saying that our emails are failing SPF.  Examining the headers, this failure is happening when our outgoing email is passed back to us from Sophos for scanning, then sent out to an external domain.  Our domain passes SPF, but earlier down the chain it's failing.

Header 4 and 5 show the SPF=pass info -- "" is my obfuscated domain name.

4 Authentication-Results spf=pass (sender IP is; dkim=pass (signature was verified);dmarc=pass action=none;compauth=pass reason=100
5 Received-SPF Pass ( domain of designates as permitted sender); client-ip=;; pr=C

Header 8 and 9 below show the fail which I'm guessing this client is seeing and their (barracuda) appliance is flagging it.

8 X-MS-Exchange-Authentication-Results spf=fail (sender IP is; dkim=pass (signature was verified);dmarc=pass action=none;
9 Received-SPF Fail ( domain of does not designate as permitted sender); client-ip=;;

To visualize this, the flow is something like this;
message sent by us to external domain
Rule to redirect to Sophos
Connector: Outbound emails to Sophos Email
Connector: Outbound emails from Sophos
email sent

So my question is, should I be adding the sophos email record ( to our SPF to mitigate this problem?  To me, it shouldn't matter as my domain, which is the final sending domain is passing the SPF check - the failure is happening between Sophos and my O365 tenant, not directly from my domain.  I'm not really seeing anything in the docs to state this other than if you're using the mail gateway.  Does it apply to mailflow too?

Edited tags
[edited by: Raphael Alganes at 5:18 AM (GMT -7) on 7 Jun 2023]
Parents Reply Children