decrypted · 19 november 2026 · supply chain · ai and llm security · digital sovereignty
A hijacked Microsoft AI package on PyPI was built to steal cloud keys
On Tuesday evening, two poisoned versions of Microsoft's official Agent Framework package appeared on PyPI, Python's public library of add-on packages. Researchers put its popularity at roughly 190,000 to 200,000 downloads a month. The new releases were rewritten to steal cloud credentials from whoever installed them. They were pulled within the hour, but the design lesson outlasts the incident.
What happened
According to StepSecurity's timeline, version 1.26.1 was uploaded at 20:35 UTC on 17 November and quarantined by PyPI at 21:06. Just over two minutes later, version 1.26.2 appeared, and it was quarantined at 21:16. The last clean release is 1.26.0. Both bad files were wheels, ready-built packages, with no matching source release. Nobody has yet explained how the attacker got permission to publish under Microsoft's name. BleepingComputer said Microsoft had not responded, and StepSecurity said the evidence does not establish the initial access route. The second upload shows the attacker kept that access after the first quarantine.
Why it was nasty
Think of a hotel master key hidden inside a delivered parcel. Normally you must open the parcel, meaning import the package, before it does anything. Here the thief used a small startup file that Python reads every time it launches. Merely having the package installed was enough, even if no code ever called it.
Once running, the code swept environment variables, configuration files and other running processes for secrets. It targeted Azure, AWS, GitHub, Docker, Hugging Face and OpenAI credentials. It also asked the cloud for fresh identity tokens: Azure managed identity and Azure DevOps tokens in both versions, with GitHub Actions tokens added in 1.26.2. The researchers stress that code analysis shows attempts, not confirmed thefts. Everything went to a public webhook service, which is itself a clue: an outbound request to an unfamiliar testing endpoint from a build server deserves an alert.
The Secure by Design lesson
This is the xz-utils class of problem in a new coat: trust in a name, rather than in what the code does. The uncomfortable part is that this was the genuine project name, so a typo-squat check would have found nothing wrong. StepSecurity noted both bad files had no provenance attestation, a signed record linking a release to the build that made it. A consumer that insisted on provenance would have refused them.
For UK organisations, the practical costs are modest:
- Pin dependencies to exact versions and hashes, and add a delay of a few days before adopting new releases.
- Block build servers from reaching the internet except for named destinations.
- Give pipelines short-lived, narrowly scoped tokens, so a stolen one is worth little.
- If anyone installed either version, do not just uninstall it. Rebuild from clean, pin 1.26.0 and rotate credentials from a separate machine, because already-issued tokens stay valid.
Your suppliers' names are not controls. Your own policy on what may run is.
Also this week
Scattered Spider. Tyler Robert Buchanan, 24, of Dundee, was sentenced in the US to six years in federal prison for stealing more than $11.6 million in cryptocurrency, The Record and BleepingComputer both report. He was arrested in Spain in 2024 and is the last of five defendants to be sentenced. His co-defendants received between two and ten years: Elbadawy and Osiebo 45 months each, Evans two years, and Urban ten years. The thefts used SIM swaps, where a phone number is hijacked to intercept codes. Text-message codes remain the weak link in too many UK accounts.
Windows Server 2028. Microsoft announced its next server release at Ignite, with a hardened Server Core setup by default. BleepingComputer lists Kerberos preferred over NTLM, SMB signing on, and the firewall on in every profile, with hundreds of settings enabled from first boot. Microsoft says work on NTLM blocking is still to come, and no release date or pricing has been given. Secure defaults are the right direction, and years overdue. Judge it when it ships.
National Cyber Force. King Charles opened the force's new headquarters, Ribble House, near Samlesbury in Lancashire on Monday. Staff are already working at the site, which the government chose five years ago. The Record notes the government has committed £5 billion to it through 2030, and that a Lords committee said the same day that ministers appear complacent on resilience. Offence is being funded handsomely. Whether defence at home gets the same energy is a fair question.
Sources
- BleepingComputer: Microsoft's Agent Framework PyPI package compromised to steal credentials
- StepSecurity: Microsoft Agent Framework PyPI package compromised
- BleepingComputer: British Scattered Spider hacker sentenced to 6 years in prison
- The Record: British hacker gets six year sentence (Scattered Spider)
- BleepingComputer: Microsoft announces Windows Server 2028 with hardened security
- The Record: King Charles opens new HQ for National Cyber Force
If your build pipelines trust more than they should, get in touch.
More like this
- Stolen GitHub tokens turned thousands of build pipelines into secret thieves 15 november 2026
- A Microsoft outage showed how one network change can stop your email 16 november 2026
- Cursor's leaked supplier key ended in a booby-trapped Claude Code extension 15 november 2026
Get the next post by email: subscribe to Decrypted. Double opt-in, unsubscribe any time, or take the RSS feed.
Prefer to listen? Decrypted on Apple Podcasts, or paste the podcast feed into any app.