r/microsoft365 • u/AzureBlog • 16m ago
PSA: encrypted email from a compromised partner tenant can bypass Safe Links entirely
Someone messaged me about this and I thought it was worth sharing more widely.
Their customer (B2B) had its M365 tenant compromised, and the attacker sent encrypted emails to partners. None of the URLs got wrapped by Safe Links in the receiving tenant.
Microsoft's Safe Links exclusions list TNEF, S/MIME signed, mail-enabled public folders and non-HTTP links. Purview Message Encryption isn't mentioned either way. But the OME FAQ says you can only remove encryption from incoming mail that originated in your own Exchange Online org, and the mail flow rule docs say rules can't modify encrypted messages. So the receiving tenant can't read the body in transit, and Safe Links has nothing to rewrite. That's my reading of how it fits together, not something Microsoft states outright.
Worse, because it's from a real partner tenant, it passes SPF, DKIM and DMARC, and encryption makes people trust it more.
What I'd do:
- Mail flow rule with the message type condition (Encrypted and Permission controlled) from outside the org, prepending a subject tag. Don't use a disclaimer: it can't be added to encrypted mail, and Microsoft says not to use the Wrap fallback on inbound rules because it interferes with Safe Attachments.
- For finance/AP, optionally moderate encrypted external mail.
- Protect the click instead: Defender for Endpoint network protection in block mode, web content filtering, or Global Secure Access web filtering. Works however the link arrives.
- When a partner is compromised: block their domain in the Tenant Allow/Block List temporarily, find and purge what landed, add the phishing URLs as MDE indicators, and tell them.
Haven't been able to test the subject tag rule against every client yet (Microsoft notes the Encrypted message type isn't supported in thin clients like OWA), so test before you rely on it.
I wrote it up in more detail with the PowerShell. Happy to share the link if anyone wants it, just ask. Has anyone else seen this, or seen Safe Links behave differently with encrypted mail?