AegisAI Perspectives · 072

What is the difference between a secure email gateway and AI-native email security?

Compare where each approach sits in mail flow, what each one sees and misses, and what running a gateway and an API layer together costs in Microsoft 365.

What is the difference between a secure email gateway and AI-native email security?

A secure email gateway sits in the mail path, because the domain's MX record points to it, and filters mail before delivery1. AI-native email security reads mail through the Microsoft 365 or Google Workspace API after delivery6. AegisAI works the second way and investigates every inbound email for what it is trying to do20. The criteria below come from Microsoft and Google documentation and name no vendor.

What you can do by the end

  • Map which mail each approach sees, from the edge of the network to mail already delivered.
  • Price the settings that running a gateway and an API layer together requires in Microsoft 365.
  • Decide between gateway only, API only, or both with a yes or no checklist and three numbers to track.

What is a secure email gateway and how does it work?

A secure email gateway is a filtering service that receives your mail first. In Exchange Online the setup rule is direct: "Your domain's MX record must point to your third-party service provider". The gateway scans each message in transit, then relays the clean ones on to Microsoft 365 through a connector.

Google Workspace works the same way. An admin enters the gateway's IP address or range in the Inbound gateway setting so Gmail knows which hop to trust12.

That position changes what Microsoft 365 sees. With a service in front, each message reaches Microsoft 365 from a different source IP address4. Microsoft's own filters then see the gateway as the sender unless you tell them otherwise.

Question to ask a vendor: which DNS and connector changes does your product need, and who owns them after go live?

What does AI-native email security read in each message?

AI-native email security connects to the mailbox platform instead of the MX record. Microsoft documents this model: some non-Microsoft services "use the Microsoft Graph API to scan messages after they're delivered to user mailboxes". Nothing in DNS changes, and mail keeps its original route.

Because it reads the mailbox, an API layer judges more than the message headers. It can compare a request with the thread it sits in and with what this sender has asked for before. This matters when authentication passes: Microsoft notes that impersonation can pass email authentication when the attacker registers a lookalike domain with valid DNS records15.

Microsoft says Graph integration commonly requires granting the outside service full access to mailboxes7.

Question to ask a vendor: which Graph or Gmail permissions does the product request, and which of them can it act with on its own?

What are the key architectural differences between a SEG and AI-native security?

The key architectural differences are position and timing. A SEG decides once in transit, while an API layer decides inside the mailbox, both before the user opens a message and after. The table sets out the criteria by approach. Built-in platform controls are the third column because every Microsoft 365 and Google Workspace tenant already has them.

CriterionSecure email gatewayAPI-based, AI-nativeBuilt-in platform controls
Where it sitsIn the mail path, MX record points to itOutside the mail path, reads the mailbox through the APIInside Microsoft 365 or Gmail
When it decidesOnce, before deliveryAfter delivery, and again when evidence changesAt delivery, with ZAP after delivery for 48 hours9
Internal mail between employeesNot routed through the MX recordVisible in the mailboxSafe Links can scan internal mail13
Sender IP that Microsoft 365 seesChanges to the gateway's IPUnchangedUnchanged
Access it needsConnector and DNS controlMailbox access granted by an adminNone beyond the license
Removal after deliveryNo reach into the mailboxPulls a message from every mailbox it reachedZAP acts on messages already in a mailbox10

A gateway is strongest on the first row of the table, and an API layer on the last two.

Check what each approach misses

Each approach has a blind spot, and Microsoft states the general rule: "total protection never reaches 100 percent"8.

A gateway misses mail it never handles. Messages sent between employees inside one Exchange Online organization stay inside Microsoft 365, which is why Safe Links has its own setting for internal senders. A compromised internal account therefore writes to colleagues without crossing the gateway. A gateway also cannot change its verdict once a message is delivered.

An API layer misses the moment before delivery. It reads a message after it lands, so a user can see the email in the seconds before removal. It also depends on the platform: if the API connection fails, its detection stops while mail keeps flowing.

In Microsoft 365, ZAP's search covers only the last 48 hours of delivered email. A message that turns bad after that window stays in the inbox unless something else removes it.

Question to ask a vendor: show me one message your product missed last quarter, and the reason it missed it.

Ask what running both costs

Running a gateway and an API layer together costs mail flow work in Exchange Online, and Microsoft documents each step.

  1. Point the MX record at the gateway and add a connector from it to Exchange Online.

  2. Turn on Enhanced Filtering for Connectors, which "is intended for scenarios where the MX record for the domain doesn't point to Microsoft 365"5.

  3. Skip that step and Microsoft warns that inbound mail gets misclassified2.

  4. Without it, mail from every internet sender appears to originate from the gateway3, so sender signals flatten.

  5. Check authentication: services that modify messages in transit break SPF and DKIM checks, and DMARC with them16. SPF fails because the message has a new source IP17.

  6. Pick one link rewriter. Another service that wraps links first might stop Safe Links from processing them14.

The API layer adds one cost of its own: full access to mailboxes for the outside service7, which your identity team must approve and review.

When does a secure email gateway still make sense?

A secure email gateway still makes sense when you must stop mail before it reaches any mailbox. That is the one thing an API layer cannot do, because it reads mail after delivery.

A policy may require that certain mail never lands, such as attachments from a blocked file type. An organization may route several mail systems through one control point. Or a team may already own a gateway with tuned rules that catch volume spam well.

The case is weaker for business email compromise. These messages often carry no link or file. IC3 logged business email compromise losses of $3,046,598,558 in 202518, and businesses reported losses over $30 million to BEC scams involving AI19. A rule that looks for bad attachments has nothing to match in a plain text payment request.

Question to ask a vendor: which of your detections need to sit before delivery, and which would work the same from the mailbox?

Which SEG and AI-native records support compliance and audit readiness?

For compliance and audit readiness, ask each approach what record it leaves of a decision, and who approved any action. Neither architecture is compliant by itself; the evidence it keeps is what an auditor reads.

A gateway keeps a log of messages it blocked or released in transit. An API layer keeps the verdict and the removal against a mailbox. Microsoft's own automated investigation queues remediation actions "for SecOps personnel to approve"11, which gives an approval trail.

Question to ask a vendor: export one verdict with its reason and the person or rule that approved the action.

How to evaluate email security for your organization

Evaluate email security for your organization by running the candidate on your own tenant and checking these items. Answer each yes or no.

  • Does it need an MX record change?
  • If it sits in front of Microsoft 365, is Enhanced Filtering for Connectors configured?
  • Does email authentication still pass after the route?
  • Does it see mail sent between two employees?
  • Can it remove a message after delivery from every mailbox it reached?
  • Does it act on mail older than 48 hours, past the ZAP window?
  • Does it judge a lookalike domain that passes authentication?
  • Is only one product rewriting links?
  • Are the mailbox permissions it holds written down and reviewed?
  • Does every verdict come with a reason your team can read?

Illustrative example, figures are fictional. A 900 person company runs a gateway in front of Microsoft 365. Over 30 days it adds an API layer in monitoring mode. The API layer flags 14 messages the gateway delivered: 9 internal messages from one compromised account and 5 payment requests from a lookalike vendor domain that passed DMARC. None of the 14 crossed the gateway in a way it could judge again. The team keeps the gateway for attachment policy and lets the API layer handle removal.

How AegisAI handles this

AegisAI reads mail through the Microsoft 365 or Google Workspace API after delivery, with no change to mail routing21. It works with an existing gateway or Defender22. It runs in monitoring mode first, and removal needs write access the admin grants and can revoke25. When a message fails, it is pulled from every inbox it reached, forwards included23. Every verdict comes with its reason in plain language, so the team can check it and share it24.

How to measure it in 30 days

Run the API layer in monitoring mode beside the gateway on your own tenant, then track three numbers.

  • Delivered and later convicted. Messages the gateway passed that the API layer flagged. These live in the API layer's verdict log.
  • Internal detections. Flags on mail between employees, which the gateway never saw. Count them separately.
  • Removal time. Minutes from delivery to removal, from the removal audit record. Compare it with the 48 hour ZAP window.

For the migration plan itself, read how to replace a secure email gateway without breaking mail flow. For the detection gaps in more depth, read why a secure email gateway still misses phishing.

Questions people ask

What is the difference between a secure email gateway and AI-native email security?

A gateway sits in the mail path through the MX record and filters mail once before delivery. AI-native email security reads the mailbox through the Microsoft 365 or Google Workspace API after delivery. The gateway can block before anyone sees a message. The API layer sees internal mail and can remove a message later.

Can AI-native email security work without a secure email gateway?

Yes, on Microsoft 365 or Google Workspace the platform's own filters still run at delivery, and the API layer reads mail after it lands. Some teams keep a gateway for policies that must act before delivery. Run both side by side and compare what each caught before deciding.

Do I still need a secure email gateway with Microsoft 365?

Not by default: Microsoft 365 filters mail at delivery and ZAP removes some messages for 48 hours afterwards. A gateway adds a control point before delivery, at the cost of connector work and Enhanced Filtering for Connectors. Keep it if a policy needs mail stopped before any mailbox receives it.

Does an API-based tool slow down email delivery?

No, because it is not in the mail path. It reads messages after Microsoft 365 or Gmail delivers them, so routing and delivery time stay as they were. The trade is a short window after delivery in which a user can see a message before the API layer removes it.

What permissions does an API-based email security tool need?

Microsoft says these Graph integrations commonly require full access to mailboxes. Ask the vendor for the exact permission list. Check that read and write access are separate grants an admin can revoke. Record the grant in your access review.

Sources

  1. Microsoft Learn, manage mail flow using a third-party cloud service with Exchange Online
  2. Microsoft Learn, Enhanced Filtering for Connectors in Exchange Online
  3. Microsoft Learn, integrate a non-Microsoft security service with Defender for Office 365
  4. Microsoft Learn, zero-hour auto purge
  5. Microsoft Learn, automated investigation and response
  6. Microsoft Learn, Safe Links
  7. Microsoft Learn, anti-phishing policies
  8. Microsoft Learn, email authentication
  9. Microsoft Learn, trusted ARC sealers
  10. Google Workspace Admin Help, set up an inbound mail gateway
  11. FBI IC3, 2025 Internet Crime Report
  12. AegisAI, inbound email security
  13. AegisAI, how to replace a secure email gateway without breaking mail flow
  14. AegisAI, why a secure email gateway still misses phishing
  15. AegisAI, see it on your own tenant

Recent posts

Every email, investigated.