Device Code Phishing
Device Code Phishing 是什么?
Device Code PhishingAn identity attack that abuses the OAuth 2.0 device authorization grant: the attacker starts a device-code flow and lures the victim into typing the resulting code on a legitimate login page, granting the attacker tokens for the victim's account.
Device code phishing weaponizes the RFC 8628 OAuth 2.0 device authorization grant, the same flow used by smart TVs, IoT devices, and CLI tools (Azure CLI, `az login --use-device-code`). The attacker initiates the flow against the target identity provider (typically Microsoft Entra ID), receiving a short user_code and a verification URL such as `https://microsoft.com/devicelogin`. They then send the victim a convincing message — meeting invite, IT-helpdesk request, support ticket — asking them to 'verify access' by visiting the (entirely legitimate) URL and entering the code. The victim authenticates with their real credentials and MFA, and the IdP issues tokens to the attacker's session, not the victim's device. Microsoft began throttling and warning on this flow in 2023–2024 and made device-code disable-by-default in some contexts in 2024 after Storm-2372 and Midnight Blizzard campaigns. Mitigations include disabling device code in Conditional Access for users who never need it, restricting it to specific managed clients, and educating users that no legitimate IT process requires them to type a code from an unsolicited message.
● 示例
- 01
A Storm-2372 operator messages a target on Teams, claims to be from IT, and asks them to verify access by entering a code at microsoft.com/devicelogin — granting the attacker an access token to the victim's mailbox and Teams.
- 02
An Entra ID Conditional Access policy blocks the device-code flow entirely for all users except a specific group of CLI users.
● 常见问题
Device Code Phishing 是什么?
An identity attack that abuses the OAuth 2.0 device authorization grant: the attacker starts a device-code flow and lures the victim into typing the resulting code on a legitimate login page, granting the attacker tokens for the victim's account. 它属于网络安全的 攻击与威胁 分类。
Device Code Phishing 是什么意思?
An identity attack that abuses the OAuth 2.0 device authorization grant: the attacker starts a device-code flow and lures the victim into typing the resulting code on a legitimate login page, granting the attacker tokens for the victim's account.
Device Code Phishing 是如何工作的?
Device code phishing weaponizes the RFC 8628 OAuth 2.0 device authorization grant, the same flow used by smart TVs, IoT devices, and CLI tools (Azure CLI, `az login --use-device-code`). The attacker initiates the flow against the target identity provider (typically Microsoft Entra ID), receiving a short user_code and a verification URL such as `https://microsoft.com/devicelogin`. They then send the victim a convincing message — meeting invite, IT-helpdesk request, support ticket — asking them to 'verify access' by visiting the (entirely legitimate) URL and entering the code. The victim authenticates with their real credentials and MFA, and the IdP issues tokens to the attacker's session, not the victim's device. Microsoft began throttling and warning on this flow in 2023–2024 and made device-code disable-by-default in some contexts in 2024 after Storm-2372 and Midnight Blizzard campaigns. Mitigations include disabling device code in Conditional Access for users who never need it, restricting it to specific managed clients, and educating users that no legitimate IT process requires them to type a code from an unsolicited message.
如何防御 Device Code Phishing?
针对 Device Code Phishing 的防御通常结合技术控制与运营实践,详见上方完整定义。
Device Code Phishing 还有哪些其他名称?
常见的别称包括: Device authorization phishing, Storm-2372 technique。
● 相关术语
- attacks№ 917
网络钓鱼
一种社会工程攻击,攻击者冒充可信方,诱骗受害者泄露凭据、转账或运行恶意软件。
- identity-access№ 839
OAuth 2.0
开放的授权框架,允许资源所有者在不共享凭据的情况下,授予第三方应用对 API 的有限范围访问。
- attacks№ 840
OAuth Consent Phishing
An identity attack that abuses the OAuth consent flow: instead of stealing a password, the attacker tricks the victim into granting their malicious app standing permissions (mail.read, files.read.all) on the victim's tenant.
- attacks№ 011
账户接管 (ATO)
犯罪者非法控制合法用户账户,用以盗取资金、数据或实施进一步欺诈的攻击。
- attacks№ 1182
社会工程学
通过心理操纵让目标执行特定行为或泄露机密信息,从而使攻击者获益的攻击方式。
- attacks№ 1191
鱼叉式网络钓鱼
针对特定个人或组织、利用事先收集的个人或职业信息精心定制的钓鱼攻击。