Microsoft 365 AiTM Phishing Detection: Signs, Logs, and Response

Microsoft 365 AiTM Phishing Detection: Signs, Logs, and Response
Published: March 24, 2026 | ByteVanguard

Threat Overview

Adversary-in-the-Middle (AiTM) phishing is one of the most dangerous identity threats in Microsoft 365 because it can undermine MFA protections by stealing an authenticated session after the user completes sign-in. Instead of simply stealing a username and password, AiTM phishing kits proxy the real sign-in flow, capture credentials, intercept MFA responses, and steal authenticated session cookies or tokens. Once replayed, those sessions can let an attacker access Microsoft 365 services as if they were the legitimate user. Microsoft’s current guidance on token theft and replay focuses on reducing risk, detecting successful theft, and limiting replay impact.

That makes detection critical. The challenge is that the initial sign-in can look legitimate. The opportunity is that replayed sessions, unusual token behavior, and post-login abuse often leave enough evidence to spot the intrusion before it turns into business email compromise, privilege escalation, or persistent access. Microsoft documents a layered approach built around Entra ID Protection, Defender XDR, sign-in telemetry, and response actions.

For a broader breakdown of how AiTM phishing works and why session theft is so effective, see our earlier analysis: AiTM Phishing: How Attackers Bypass MFA and Hijack Sessions.

Why AiTM phishing is harder to catch

Traditional phishing usually ends with stolen credentials. AiTM goes further by sitting in the middle of a live authentication session. The victim believes they are signing in normally, completes MFA, and the attacker captures the resulting session artifacts. That means defenders may see a valid-looking login followed by suspicious activity from another IP address, browser, device context, or geography. Microsoft’s published investigations of AiTM campaigns repeatedly tie these attacks to session cookie theft, replay, and downstream fraud activity.

The Microsoft signals that matter most

Microsoft Entra ID Protection includes detections directly relevant to session theft and AiTM-style activity. The most important ones to monitor include:

  • Attacker in the Middle
  • Anomalous token
  • Unfamiliar sign-in properties

These detections matter because they focus on the exact kinds of inconsistencies common in session replay attacks: unusual token use, unexpected sign-in characteristics, and suspicious changes in context. Microsoft’s token protection guidance also emphasizes that detection should be paired with preventive controls designed to limit replay value.

Microsoft Defender XDR also documents a session cookie theft alert workflow specifically tied to AiTM-style attacks. Its public playbook is built around investigating suspicious behavior indicative of an AiTM-type attack for cookie theft and determining whether the alert is a true positive or false positive.

What to look for in Entra sign-in logs

Even without every premium detection enabled, sign-in logs can still reveal strong hunting leads.

1. Multiple successful sign-ins from different IPs in a short period

A common pattern is a legitimate user authenticating through the phishing proxy, followed by the attacker replaying the session from another location shortly after. One IP change alone is not enough, but rapid changes paired with new ASN, browser, or device context deserve review.

SigninLogs
| where TimeGenerated > ago(1h)
| where ResultType == 0
| summarize distinct_IPs = dcount(IPAddress), IPs = make_set(IPAddress, 10) by UserPrincipalName
| where distinct_IPs > 1

2. Impossible travel or unusual location right after MFA

The first sign-in may look normal because the victim completed it. The stronger clue is often the next successful session from a geography or network profile that does not fit the user’s normal pattern. Microsoft’s risk detections are built to surface this kind of abnormal sign-in context.

3. Weak or missing device trust context

Replay activity often lacks the same device assurances as the victim’s real session. A sign-in from an unmanaged or previously unseen device is not automatically malicious, but it becomes much more interesting when paired with unusual IP, location, or risky token behavior.

4. Suspicious user-agent, ISP, or anonymizer use

Microsoft’s token theft playbook calls for investigating suspicious sign-in properties around token theft incidents. In practice, that includes unexpected user agents, cloud-hosted infrastructure, residential proxy patterns, or anonymization services.

The clearest evidence often appears after login

In real Microsoft 365 incidents, the strongest evidence of AiTM is often not the authentication event itself but what happens next.

Watch for:

  • new inbox rules that hide or forward messages
  • unusual SharePoint or OneDrive browsing and downloads
  • sudden access to finance, executive, or admin mailboxes
  • suspicious OAuth app consent activity
  • access to Entra, Azure, or Microsoft 365 admin portals from unfamiliar context
  • bulk email activity consistent with BEC staging

Microsoft’s investigations into AiTM and token theft show that these attacks frequently lead to follow-on actions such as session replay, cloud abuse, and financially motivated activity.

A practical detection workflow

Start with native alerts

Review Entra ID Protection and Defender XDR alerts first. Even one low-volume session theft signal can matter because replayed sessions often give attackers immediate access. Microsoft’s session-cookie theft playbook exists for exactly this scenario.

Pivot into sign-in telemetry

Build a short timeline around the user:

  • IP address
  • location
  • ASN
  • device context
  • application accessed
  • client app
  • user agent
  • sign-in risk

Look for a normal-looking sign-in followed quickly by another session with a different environment.

Check for business-impact activity

Review Exchange, SharePoint, OneDrive, admin actions, OAuth consents, and mailbox rule creation. This step often tells you faster than the initial login whether the account was actually abused.

Contain quickly

If risk is confirmed, do more than reset the password. Microsoft’s guidance on token theft and remediation focuses on revoking sessions, reviewing added credentials or devices, and investigating related malicious email or follow-on activity.

Useful KQL starting points

Timeline of successful sign-ins

SigninLogs
| where TimeGenerated > ago(24h)
| where ResultType == 0
| project TimeGenerated, UserPrincipalName, IPAddress, Location, AppDisplayName, ClientAppUsed, UserAgent
| order by UserPrincipalName asc, TimeGenerated asc

Successful sign-ins with risk indicators

SigninLogs
| where TimeGenerated > ago(24h)
| where ResultType == 0
| where RiskLevelDuringSignIn in ("medium", "high") or RiskDetail != "none"
| project TimeGenerated, UserPrincipalName, IPAddress, Location, AppDisplayName, RiskLevelDuringSignIn, RiskDetail
| order by TimeGenerated desc

Prevention still matters

Detection is only part of the answer because AiTM attacks abuse valid sessions. Microsoft’s current token guidance emphasizes defense in depth: harden devices, reduce exposure to risky destinations, use device-based and risk-based controls, and protect against replay where supported.

The highest-value controls are:

  • phishing-resistant MFA such as FIDO2 or passkeys
  • Conditional Access
  • token protection in supported scenarios
  • shorter, risk-aware session persistence
  • Defender for Office 365 protections
  • user training focused on fake Microsoft sign-in flows and consent abuse

Token protection deserves special attention. Microsoft describes it as part of a broader strategy to block replay or reduce the impact of successful token theft by enforcing device-bound tokens in supported scenarios. It is powerful, but it is not a magic fix for every workflow or client.

Final take

AiTM phishing is dangerous because it turns a legitimate-looking login into a stolen trusted session. That is why defenders who think only in terms of passwords and MFA prompts often miss it. The organizations with the best chance of catching it early are the ones that correlate Entra detections, Defender XDR alerts, sign-in anomalies, and post-login abuse.

The login may look normal. The session often does not.

Sources & Further Reading

  • Microsoft Security Blog (January 21, 2026)
    Resurgence of a multi-stage AiTM phishing and BEC campaign abusing SharePoint
    Read the full report
  • Microsoft Learn
    What are risk detections? (Entra ID Protection)
    View documentation
  • Microsoft Learn
    Protecting tokens in Microsoft Entra ID
    Read the guidance
  • Microsoft Learn
    Token Protection in Microsoft Entra Conditional Access
    View details
  • Microsoft Learn
    Investigate risk with Microsoft Entra ID Protection
    Read the playbook
  • Microsoft Learn
    Alert grading for session cookie theft alert (Microsoft Defender XDR)
    View alert guidance

These sources provide the latest insights into AiTM mechanics, Entra ID risk detections (including Attacker in the Middle, Anomalous token, and Unfamiliar sign-in properties), token protection features, session cookie theft alerts, and practical hunting/remediation steps.

Support independent security analysis

If you find ByteVanguard useful, you can support the site and help keep the analysis independent.

Support the analysis
Intelligence over headlines. Signal over noise.

Stay Connected

Report Intelligence
© 2026 ByteVanguard. Built for security professionals.