Suspicious Microsoft Entra Device Code Authentication Flow

PremiumReviewedSigma · Medium · v1
Product
azure
Service
signinlogs
Author
HuntRule
Published
2026-10-25
Updated
2026-10-25

ATT&CK techniques

Initial Access → Cred Access

What it detects

This rule detects sign-ins that complete through the OAuth device code authentication protocol in Microsoft Entra. The EvilTokens phishing-as-a-service kit abuses the device code flow to trick victims into authorising attacker controlled devices and harvest refresh tokens. Because device code is uncommon for ordinary interactive users its appearance should be reviewed against expected device enrollment activity.

Related detections9 linkedT1528 — drag to rearrange
Suspicious OAuth Application Consent Grant via Azure Audit Logs
Suspicious Salesforce Connected App OAuth Authorization from VPN Egress
Suspicious M365 Device Code Authentication Flow via m365
Suspicious OAuth Device Code Sign-In to Authentication Broker via Tycoon 2FA
Suspicious OAuth Sign-In Using Visual Studio Code Client and Auth Broker
Suspicious AWS Console Phishing MFA Relay Endpoints
Suspicious AWS AiTM Phishing Kit Endpoint Access via Proxy
Suspicious Entra ID Device Code Flow Authentication
Suspicious OAuth Application Registration with Localhost Reply URL via Azure AD
Suspicious Microsoft Entra Device Code Authentication Flow
Pivot detection · T1528 · 9 related

Detection content is published as a reviewed draft. Tune thresholds and exclusions against your own telemetry before enabling this rule for alerting.