Microsoft 365 device code phishing adds attackers' devices to company accounts
Huntress found 468 rogue devices registered in 305 Microsoft 365 organizations in November. A password reset alone does not remove them.
On December 3, 2026, security firm Huntress reported a phishing campaign that quietly adds the attacker's own "computers" to victims' Microsoft 365 accounts. Throughout November 2026, Huntress found 468 rogue device registrations across 326 user accounts in 305 organizations. The detail that matters most for small businesses: changing the victim's password does not lock the attacker out.

How the attack works
The campaign abuses device code sign-in, a legitimate Microsoft feature meant for devices without a keyboard, such as smart TVs or conference room screens. Huntress describes the sequence like this:
- The victim receives a phishing lure and is walked through a real Microsoft sign-in page where they enter a short code. Because the page is genuine, it looks safe, and the user completes multi-factor authentication as normal.
- That sign-in hands the attacker valid tokens for the account.
- The attacker immediately uses those tokens to register a new Windows device in the company's Microsoft Entra ID (the identity system behind Microsoft 365). Huntress says it appears the attacker uses ROADtools, a public toolkit.
- The registered device receives a Primary Refresh Token, which gives single sign-on to the user's Microsoft 365 apps such as Outlook, OneDrive and SharePoint, and can even satisfy access policies that require a registered device.
Why a password reset is not enough
Huntress points out that Microsoft only invalidates this kind of token on a password change when the token was obtained with the password. Here it came from a phished sign-in, so the attacker's device keeps working. According to Huntress, deleting the rogue device in Entra ID is the only way to cut off access.
What to check in your Microsoft 365 tenant
- Look at the device list in the Microsoft Entra admin center. The rogue devices in this campaign were named MH- followed by 16 letters and numbers (for example MH-51FB898341CEA47A) and reported Windows build 10.0.19041.928, a Windows 10 version long out of support. Any device nobody recognizes deserves a question, whatever its name.
- Check the sign-in logs for device code sign-ins and for sign-ins from unfamiliar locations or from scripts rather than browsers. Our guide to reading Microsoft 365 sign-in logs explains where to look.
- If you find one: delete the device, revoke the user's sessions, reset the password, review the user's MFA methods and remove any you don't recognize, and check the mailbox for forwarding or inbox rules the user did not create.
How to prevent it
- Block device code sign-in if you don't use it. With Microsoft Entra ID P1 (included in Microsoft 365 Business Premium), a Conditional Access policy can block the device code flow for everyone except specific accounts that genuinely need it.
- Restrict device registration. Limit who can register or join devices, cap the number per user, and require MFA to register a device.
- Without P1 licences, make sure Security Defaults are turned on.
- Tell staff: if an email, document or chat message asks them to type a code into a Microsoft page, they should stop and check with IT first. A genuine Microsoft page is exactly what makes this lure convincing.
This is a close relative of the token replay attacks we wrote about earlier: MFA is still essential, but attackers are increasingly targeting what happens after the sign-in.
Sources
- Huntress, M365 Device Code Phishing Campaign Leads to Hundreds of Rogue Entra ID Registrations, December 3, 2026.
- UC Today, Huntress Tracks 468 Rogue Entra Devices in M365 Phishing, December 2026.
Want someone to check your tenant?
Call Creative IT USA on (213) 986-4855. We can review your registered devices and sign-in settings as part of our email and phishing security work.