Forum Discussion
Exchange Online Protection SPF record
I see the same thing happing with emails send from an application and using Office365 as SMTP.
The address: 2603:10a6:102:1ce:6 is not in the record spf.protection.outlook.com
Looks like MS is not updating the record, or there are servers which a sending emails which should not be going on the internet that route.
Which IPv6 range should be added, any one an idea? Not planning on manually adding each IP address.
- jabberwockdb123Oct 07, 2022Copper ContributorI used "v=spf1 ip6:2603:10b6::/37 include:secureserver.net ~all". I believe it includes most IP's starting with 2603:10b6 which overcompensates. But I couldn't think of any other way. Most of the emails pass through with this, but I still see some IP's which are not designated... For example 2603:10b6:a03:202::9 is not designated.
Another odd thing is when I receive an email via Gmail, even if the email passes SPF, Gmail sometimes flags it as possible spam.- JohnLBevanFeb 15, 2024Copper ContributorI've done a few tests now and think I can explain it...
I see 2603:10b6::/37 IPs show up when I send emails to other mailboxes under our tenant.
However, if I send mails externally (e.g. to a gmail address) I see the IPs listed in the SPF record (e.g. 2a01:111:f403:261b::700).
Similarly, mails sent internally don't include a DKIM selector (header.s=selector1 / header.s=selector2), whislt those sent externally do.
So I think this behaviour may be by design; but (to the best of my Google-fu) I can't find this documented anywhere.
i.e. When mails are sent internally, MS already knows they're valid, so doesn't bother following the normal processes which would allow a mail to be verified via DMARC. But when mails are sent externally it does use an IP covered by SPF and a selector covered by DKIM as expected.
That's my theory though; not a verified fact.- JohnLBevanFeb 22, 2024Copper ContributorMore info on this thread: https://serverfault.com/questions/1154095/spf-spf-protection-outlook-com-is-invalid-for-messages-within-tenant/1154098#1154098
It looks likely that SPF and DKIM are not relevant when the header `X-MS-Exchange-Organization-AuthAs` has value `Internal`.
- AdamS550Dec 04, 2023Copper Contributor
we had the same issue all of sudden most of our emails was marked spam and when we contacted MS support they fallow the standard MS support spam filter, email policies ..etc even though we clearly told them it seems the emails that was send from IPV6 like 2603:10c6:10:e::17 it was marked as spam and this IP is belong MS. why is that? after 3 days of none sense and lost of emails we did our investigation
https://www.spf-record.com/spf-lookup/spf.protection.outlook.com?ip=2603:10c6:10:e::17
IPV6 start with 2603: is not part of spf recorders that cause our email to fails SPF check further more the entire 2603:1000::/24 is belong to Microsoft network.
since we added the ipv6 record to our spf record our email seems to be fine
v=spf1 include:spf.protection.outlook.com ip6:2603:1000::/24 -all
until MS figure out how to implement basic things like SPF 🙂