The malicious versions used a .pth hook, a mechanism that ran the code automatically whenever the Python interpreter started. Users did not have to import anything or call a function. Starting Python in an affected environment was enough to set it off.
The code went after secrets that open doors across an organization: Azure CLI credentials, along with GitHub Actions and DevOps tokens. It also hunted for environment variables and credential files tied to npm, pip, Docker, Git and Hugging Face.
PyPI quarantined the malicious code within about an hour of upload, around 21:30 UTC. An hour is fast by incident-response standards. It is also plenty of time for automated build systems that grab the newest version the moment it appears.
The download numbers explain why that window matters. The ‘agent-framework’ package sees roughly 190,000 to 200,000 downloads per month on PyPI.
Microsoft’s response and the open-ended outage
In a November 25 update, Dan Taylor, principal product architect at Microsoft, said the repository would stay unavailable until the company could establish it was safe to bring back. He offered no timeline.
Taylor apologized for the extended downtime and called it a necessary precaution while Microsoft secures the project. He also said the malicious code was not present in the source repository and that the project would not be discontinued.
The guidance for users is blunt. Anyone who installed versions 1.26.1 or 1.26.2 should treat their environment as compromised and rotate all credentials immediately. The last clean release was version 1.26.0, published on November 12.
Why Agent Framework is a notable target
Microsoft Agent Framework is the successor to two earlier Microsoft projects, AutoGen and Semantic Kernel. Version 1.0 arrived on April 3, 2026, and Microsoft pitched the framework as its consolidated toolkit for building AI agents.
That lineage gives the package a built-in audience. Developers who used AutoGen or Semantic Kernel had a natural path into Agent Framework, which helps explain the download numbers.
What this means for developers and organizations
For everyone else, the episode shows that a trusted name on a package does not guarantee a trusted release. Microsoft says the source code was clean. The problem was the distribution channel.
Two practical lessons follow. Pinning dependencies to known versions, such as 1.26.0 in this case, would have kept environments from automatically pulling the unauthorized releases. Limiting what credentials sit in build environments shrinks the payoff for any code that does slip through.
Three things are worth watching: when Microsoft restores the repository, what it discloses about how the unauthorized releases were published, and whether it changes how Agent Framework packages reach PyPI going forward. Until then, version 1.26.0 is the line between clean and compromised.