
Illustration
Companies3 min read
Hackers hijack Microsoft's Agent Framework on PyPI to steal cloud keys
Attackers hijacked the Python package for Microsoft's Agent Framework on PyPI and published malicious versions 1.26.1 and 1.26.2 on 17 November, BleepingComputer and several security firms reported. The code collected credentials for Azure, AWS, GitHub, OpenAI and other services when Python started and sent them to an outside server, BleepingComputer said.
Key facts
- Hijacked versions 1.26.1 and 1.26.2 of Microsoft's Agent Framework appeared on PyPI on 17 November 2026, according to Socket and BleepingComputer.
- The malware collected environment variables, .env files and credentials for Azure, GitHub, Docker, Hugging Face and OpenAI, Socket said.
- Version 1.26.0 is clean, according to BleepingComputer; Socket advises rotating any credentials that may have been exposed.
Researched and written with AI, to Luigi's brief, positions and editorial rules. Automatically checked against the sources. How I work →
Both releases appeared on PyPI, the main index for Python packages, on 17 November, according to security firm Socket. Each still installed the genuine core library at version 1.26.0, so the framework kept working normally, BleepingComputer reported. The package gets close to 200,000 downloads a month, according to The Register. On PyPI, 1.26.0 from 12 November is again the latest release.
After PyPI quarantined the first release, the attacker published a second about two and a half minutes later, which was quarantined roughly eight minutes after that, BleepingComputer wrote. That means the attacker still had publishing rights after the first takedown. How they got access is unclear. The Register said the activity appears to involve an administrator account in Microsoft's GitHub organisation, but that has not been confirmed.
What the Agent Framework malware stole
The code ran every time Python started, even if no program imported the package, according to BleepingComputer. It collected whatever sat in the environment:
- environment variables containing strings such as TOKEN, SECRET, KEY, AZURE, AWS, GITHUB or OPENAI (Socket),
- credential files for pip, npm, Git, Docker and Hugging Face, plus application .env files (Socket),
- fresh tokens from Azure, Azure DevOps and, in version 1.26.2, GitHub Actions (BleepingComputer).
The data was sent to an address on the webhook.site service, according to BleepingComputer. Socket advises removing both versions and rotating any credentials that may have been exposed. BleepingComputer recommends isolating affected machines and rebuilding from a clean environment with 1.26.0.
Microsoft told The Register it had made some repositories private while it investigated malicious content and that its priority was protecting customers. The Agent Framework's GitHub repository was offline at the time, The Register reported.
Microsoft Agent Framework: a toolkit for AI agents
According to PyPI, Agent Framework is Microsoft's Python package for building AI agents, with integrations for Azure OpenAI, OpenAI and Microsoft Foundry. Anyone building agents with it usually keeps the keys the malware was looking for in that same environment. The case follows other attacks on marketing and AI tools in recent days, including one via an Optimizely A/B testing script and one through agent logs at the supplier Fireworks.
Analysis
An agent framework is not an ordinary package. It runs where an agent is meant to work, and that is where the keys for models, cloud, code and often the CRM live. Teams that update such a package automatically hand every update the whole keyring. The second malicious release was live for about eight minutes, BleepingComputer said; any team updating automatically in that window installed it before anyone could review it.
For marketing teams and agencies having agents built for campaigns, reporting or lead handling, this is about foundations. Pinned version numbers instead of automatic updates, a separate key with narrow rights for each agent and a list of who is responsible for which agent are unglamorous, but they decide whether a hijacked package is a nuisance or a data leak. Microsoft is moving the same way with containers for AI agents in Windows 11. Teams just starting out will find the basics in the guide to AI agents for marketing. Agencies running agents for clients should now confirm in writing whether version 1.26.1 or 1.26.2 was installed anywhere.
Got AI news? Submit news →
FAQ
Which versions of Microsoft Agent Framework are affected?
Versions 1.26.1 and 1.26.2, published on PyPI on 17 November 2026. Version 1.26.0 is clean, according to BleepingComputer, and is again the latest release on PyPI.
What should Agent Framework users do now?
Socket advises removing both versions and rotating any credentials that may have been exposed. BleepingComputer also recommends isolating affected environments and rebuilding cleanly with 1.26.0.
Source
BleepingComputer: Microsoft's Agent Framework PyPI package compromised to steal credentials
More sources
- Socket – Analyse der Sicherheitsfirma, Liste der gesuchten Zugangsdaten.
- The Register – Microsoft-Stellungnahme, Downloads pro Monat.
- PyPI – Versionsliste (1.26.0 vom 12.11.2026 neueste), Paketbeschreibung.



