Research

Device Code Phishing Planted 468 Rogue Windows Devices in 305 Entra Tenants. A Password Reset Does Not Evict Them: Delete the Device First, Then Block Device Code Flow

Device Code Phishing Planted 468 Rogue Windows Devices in 305 Entra Tenants. A Password Reset Does Not Evict Them: Delete the Device First, Then Block Device Code Flow

What to do first. If you run a Microsoft 365 tenant, open the Microsoft Entra admin center, go to Devices, then All devices, and sort by registration date. Look at everything registered since November 1. Any device whose name starts with MH- followed by 16 hex characters, any device reporting OS version 10.0.19041.928, and any device you cannot tie to a real laptop: delete it. Then revoke that user's sessions and reset their password, in that order. A password reset on its own leaves the attacker signed in, because the rogue device holds a Primary Refresh Token that survives the reset.

Then close the door. If nobody in your tenant signs in to TVs, conference room panels or command-line tools with a code, create a Conditional Access policy that blocks the device code flow (steps below). It is one policy, it takes ten minutes, and it removes the step this whole campaign depends on.

What is confirmed

Huntress, the managed detection and response company, published the research on December 3, 2026. Their count, in their words: "Throughout November 2026, we observed 468 registrations across 326 identities in 305 organizations." The population behind those numbers is Huntress's own customer base: tenants whose Microsoft 365 and Entra logs Huntress collects. The true total across all of Microsoft 365 is larger by an amount nobody outside Microsoft knows.

How the attack works, per Huntress:

  • The lure is a device code. The victim is sent a code and told to enter it on Microsoft's real sign-in page. The page is genuine, so nothing looks wrong. Entering the code hands the attacker an access token and a refresh token for the Microsoft Authentication Broker application. Huntress saw the lure dressed as an Adobe-protected non-disclosure agreement.
  • The token is spent on a device. Within seconds the attacker redeems the token against Entra's device registration service and joins a Windows device it controls to the victim's tenant. That device gets a Primary Refresh Token (PRT): single sign-on to the user's Microsoft 365 apps.
  • The PRT outlives the password. Huntress explains that Microsoft invalidates a PRT on a password change only when the token came from the password. Here it came from a phished token, so the reset does nothing to it. A PRT can also satisfy Conditional Access policies that require a registered device. The device has to be deleted.
  • Then the data. After registration the attacker signed in to Entra and Microsoft Office, and in many cases went on to OneDrive, SharePoint and Exchange.

What the rogue devices look like:

  • Most are named MH- plus 16 uppercase hex characters (for example MH-51FB898341CEA47A). Huntress saw 46 such names registered in more than one organization; MH-51FB898341CEA47A alone appeared in 24 organizations over 10 days.
  • Every one was Entra-joined and reported Windows build 10.0.19041.928, which is the default hardcoded in ROADtools, a public Entra research toolkit. That build is Windows 10 version 2004, out of Microsoft servicing since 2021. A patched real machine does not report it.
  • None carried hardware identifiers.
  • ROADtools registers with the user agent Dsreg/10.0 (Windows 10.0.19041.928).

Huntress grouped what it found into three operations:

  • Operation A, the MH- devices plus some DESKTOP- devices. Phishing sign-ins came through residential proxy networks (Huntress names DataImpulse, Oxylabs, NodeMaven, IPRoyal and Shifter), mostly US and UK broadband. Scripted follow-up sign-ins used python-requests/2.32.5 from five datacenter IPs, rotated one at a time. Huntress rates the MH- link high confidence.
  • Operation B registers a device named after the victim's username and email domain, then a second one named DESKTOP- plus six characters within 28 minutes. Headless Chrome on Linux, python-requests/2.34.2, its own sign-in IPs. High confidence.
  • Operation C uses names like Device- plus eight hex characters and GraphSpy-Device (the default in GraphSpy, another public toolkit), build 10.0.26100, from datacenter IPs. Low confidence that it is related at all.

Huntress also measured what Microsoft's own tooling caught: of the organizations with an MH- device, 36 had Microsoft Defender connected to Huntress. Those 36 held 47 victims, and Defender opened an incident on 25 of them, titled "User session compromised by device code phishing (attack disruption)." So where Defender was present, it caught about half. The Entra logs found the rest.

What is not known

  • Who. Huntress did not tie any of the three operations to a named actor. The chain matches what Microsoft documented for Storm-2372 in February 2025, but ROADtools and GraphSpy are public, so a shared default proves nothing about identity.
  • How the lures were delivered at scale (email, Teams, something else) beyond the Adobe NDA theme.
  • How many tenants outside Huntress's view are affected.
  • What was taken. Huntress describes access to OneDrive, SharePoint and Exchange, not a count of exfiltrated files.

What to do

1. Find rogue devices (any license). Entra admin center, then Devices, then All devices. Add the columns Join type, OS version and Registered, and sort by Registered. Flag:

  • names matching MH- plus 16 hex characters, DESKTOP- plus six or eight characters that you did not image, Device- plus eight hex, or GraphSpy-Device;
  • OS version 10.0.19041.928, 10.0.19045.2006, 10.0.19045.0 or 10.0.26100 on a device with no hardware identifiers or no Intune record;
  • any user whose device count jumped in November.

2. Read the audit log. Entra admin center, then Monitoring and health, then Audit logs. Filter Category to Device and Activity to "Register device" and "Add device". Note the initiating user and time for each hit, then pull that user's sign-ins for the same few minutes.

3. Read the sign-in logs for device code. Monitoring and health, then Sign-in logs. Add the filter Authentication protocol and set it to Device code. Check both the User sign-ins (interactive) and User sign-ins (non-interactive) tabs. Huntress's tell: an interactive sign-in to Microsoft Authentication Broker (application ID 29d9ed98-a469-4536-ade2-f981bc1d605e) with error code AADSTS50199, followed minutes later by a non-interactive sign-in from a different country with a programmatic user agent such as python-requests, node, axios or undici. Follow the session ID; that is how Huntress traced each intrusion.

4. If you have Sentinel or Defender Advanced Hunting, turn those into queries. In words, since our blog cannot render code:

  • In the SigninLogs table, filter where AuthenticationProtocol equals deviceCode over the last 35 days, and list user, app, IP, country and session ID. Anything outside your known device-code users is a lead.
  • In the AADNonInteractiveUserSignInLogs table, filter where UserAgent contains python-requests, python-httpx, node-fetch, undici or axios, and join on user to the deviceCode results above. A device-code sign-in followed by a scripted one is the campaign shape.
  • In the AuditLogs table, filter where OperationName is "Register device" or "Add device", expand the modified properties, and match device display names against the MH- pattern or an OS version of 10.0.19041.928.
  • Search both sign-in tables for the five IP addresses listed below.

5. If you get a hit, evict in this order. Delete (or first disable, then delete) the rogue device in Entra. Then revoke the user's sessions: on the user's page in the Entra admin center, choose Revoke sessions. Then reset the password and re-register the user's MFA methods, removing any method you do not recognize. Check the mailbox for new inbox rules, forwarding and deleted-items rules, and review that user's OneDrive and SharePoint file access for November. Huntress puts device removal first; doing the reset first leaves the PRT alive.

6. Block device code flow with Conditional Access (Entra ID P1 or higher). Entra admin center, then Protection, then Conditional Access, then New policy. Users: all users, excluding a break-glass account and any group that genuinely needs device code (for example a Teams Rooms service account). Target resources: all resources. Conditions: Authentication flows, then tick Device code flow. Grant: Block access. Start it in report-only for a few days, read who would have been blocked, then turn it on. Microsoft itself recommends blocking device code wherever it is not needed.

7. Make device registration harder. Devices, then Device settings: limit "Users may join devices to Microsoft Entra" to a group that actually provisions laptops, lower "Maximum number of devices per user", and require MFA to register or join devices (better done as a Conditional Access policy on the "Register or join devices" user action). Tenants without P1 should turn on Security defaults. P2 tenants should add sign-in risk and user risk policies.

8. Tell your users one sentence. Never type a code into microsoft.com/devicelogin unless you started the sign-in yourself on a device in front of you. A code someone sends you is a key to your account.

How we know, and what we checked

We read the Huntress write-up directly; BleepingComputer's report (December 3) summarizes it and adds no separate data, so this is one source.

Indicators. Huntress published five datacenter IPs used for Operation A's scripted sign-ins, plus device-name patterns and user agents. We ran each IP through our correlate graph and enrichment before ingesting:

  • None of the five was held in our corpus before today, and none had a same-/24 neighbor in our graph.
  • 181.214.147.42 sits inside 181.214.147.0/24, which our feed already carried from Spamhaus DROP (SBL693543). That is block-coverage by a public list we redistribute, not a detection of this campaign by us.
  • None of the five appears in our edge block events or edge canaries.

We added the five IPs to our feed with attribution to Huntress, at confidence 80 (85 for the one Huntress lists as still in use). Two cautions. Huntress rotated through these one at a time, and four of the five were already retired by publication, so these are mostly for hunting back through November logs, not for stopping tomorrow's sign-in. And Huntress notes the residential proxy IPs used for the phishing sign-ins never served more than two victims each, so an IP blocklist will not stop this attack. Conditional Access will. The device names and user agents are hunt keys for your Entra logs, not network indicators, so they are listed here and not fed.

Our edge. This is an identity-plane attack between the victim, Microsoft's sign-in service and the attacker. Our web edge does not sit in that path. We still checked: our edge saw no request carrying the ROADtools Dsreg/10.0 user agent since November 1 (0 matches in 701,944 edge block records, 115,093 canary records and 1,016 origin honeypot captures). That says nothing about your tenant.

We do not claim to have seen this campaign before Huntress did. We did not.

Block these with our free feed. Docs at docs.dugganusa.com. Sentinel users can pull the feed with the built-in Threat Intelligence TAXII connector: setup at docs.dugganusa.com/siem/sentinel/.

Datacenter IPs (Operation A scripted sign-ins, in order of first use, per Huntress):

  • 181.214.147.42 (BK Customers; 16 days; 51 accounts in 49 organizations)
  • 92.62.251.249 (FREAKHOSTING LTD; 8 days; 95 accounts in 89 organizations)
  • 37.252.11.196 (Artnet Sp. z o.o.; 4 days; 79 accounts in 73 organizations)
  • 146.103.38.149 (BK Customers; 5 days; 81 accounts in 78 organizations)
  • 193.109.193.166 (Datacamp Limited; still in use at publication; 60 accounts in 54 organizations)

Device name pattern: MH- followed by exactly 16 uppercase hex characters. Most reused names, with the number of organizations Huntress saw each in: MH-51FB898341CEA47A (24), MH-AD72DAD766A59028 (18), MH-4AE06D5094ABCAD7 (17), MH-F80EA97CA5FB3E90 (14), MH-8588A5E037F15197 (11), MH-0355F2C9C8243D00 (6), MH-0A25978CCAE9BF67 (6), MH-88FC3793D7573345 (6), MH-711B0E99A370D9AE (6), MH-565CE7A7663C3537 (6), MH-5A7AEAE27625C08C (5). Huntress lists 16 more names seen in two or three organizations.

Reported OS builds on rogue devices: 10.0.19041.928 (ROADtools default), 10.0.19045.2006, 10.0.19045.0, 10.0.26100.

User agents to look for in non-interactive sign-ins: python-requests (2.32.5 for Operation A, 2.34.2 for Operation B), python-httpx, node, node-fetch, undici, axios, Dsreg/10.0, and HeadlessChrome on Linux. Several of these are also used by legitimate automation in some tenants, so treat them as a filter to read, not a verdict.

Block every IP above with our free feed.

Am I affected?

You are affected if, in your Entra tenant, any of these are true: a device registered since November 1 matches the MH- pattern or reports build 10.0.19041.928 with no hardware identifiers; a user has a device-code sign-in to Microsoft Authentication Broker they cannot explain; or the five IPs above appear in your sign-in logs. If none are true, you were not hit by this wave as Huntress describes it. You are still exposed to the next one until device code flow is blocked.

Sources

  • Huntress, "M365 Device Code Phishing Campaign Leads to Hundreds of Rogue Entra ID Registrations," December 3, 2026: huntress.com/blog/device-code-phishing-m365-registrations
  • BleepingComputer, "Device-code phishing campaign plants rogue devices in 305 Entra tenants," Bill Toulas, December 3, 2026
  • Microsoft Threat Intelligence on Storm-2372 device code phishing, February 2025 (cited by Huntress)

Read next: Two New Phishing Kits Walk Around Your Microsoft 365 MFA From Opposite Directions, our July look at Jalisco, the ReliaQuest-documented kit that phishes Microsoft 365 through device codes and never asks for a password.


Every indicator in this post is in the feed. Free.

1.58M+ IOCs, STIX 2.1 / TAXII, 88% novel vs ThreatFox, exploited-CVE leads ahead of CISA. No credit card — a free API key in 30 seconds, and you can audit every claim above against the live endpoints.

Get your free key → analytics.dugganusa.com/stix/register