An Agent Framework attack targeted developers on November 17, when someone published two malicious releases of Microsoft’s official Python package on PyPI. Versions 1.26.1 and 1.26.2 contained code that could steal cloud credentials as soon as Python started, even if the developer never imported the toolkit.

The toolkit kept working while the stealer ran

Developers use Microsoft’s open-source Agent Framework to build AI agents and coordinate their work. Its PyPI package receives roughly 200,000 downloads a month. Both malicious releases continued to use the legitimate agent-framework-core version 1.26.0, so applications could still run normally while the added code searched for secrets in the background.

The first release searched environment variables and local configuration files for credentials associated with Azure, AWS, GitHub, Docker, Hugging Face and OpenAI. Where permissions allowed, it also looked for secrets in other running processes. On Azure systems, the code tried to obtain tokens that workloads use to access cloud resources, including managed identity and Azure DevOps tokens.

A second release reached PyPI minutes after quarantine

PyPI quarantined version 1.26.1, but the attacker published version 1.26.2 roughly two and a half minutes later. The second release expanded the search to directories on GitHub Actions runners, the machines that execute automated workflows. It also tried to obtain identity tokens for those workflows. Both releases sent the data they collected to the same external destination.

PyPI quarantined the second release about eight minutes after it appeared. Although the first quarantine restricted access to that release, the attacker still had permission to publish another version under the official project. As of November 18, it remained unclear how the attacker had gained that access.

What to check after installing an affected version

Developers who installed either release should isolate the affected environment and avoid running Python or pip there until they secure it. Because the stealer ran during normal Python startup, even an unrelated script could have triggered it. Teams should rebuild from a known-clean environment using version 1.26.0 and immediately rotate any credentials the affected environment could access.

To assess the impact of the Agent Framework attack, investigators can check outbound network logs for requests to the specific webhook path associated with both releases. The outcome matters as much as the destination. A blocked request shows an attempted connection, while a completed transfer provides evidence that data left the environment.


0 responses to “Agent Framework attack targets developers’ credentials”