Microsoft's agent-framework PyPI releases steal cloud and CI credentials at Python startup
Malicious agent-framework 1.26.1 and 1.26.2 wheels install Python startup hooks that collect secrets and request cloud/CI identity tokens. Microsoft confirms both versions were removed. Remove hooks before running pip, restore the clean 1.26.0 release and respond to credential exposure.
- Disclosed
- Nov 17, 2026
- Updated Nov 19, 2026
- Severity
- Septic Tank Blew
- No CVE: a breach, not a bug
- Splash zone
- Python environments, CI runners and images with agent-framework 1.26.1 or 1.26.2; startup hooks run without a framework import
- python
- In the wild
- Yes
- Microsoft confirms malicious releases; researchers analyzed the published wheels.
What happened
This is a compromise of the published Python meta-package, not evidence that every Agent Framework component or Microsoft’s source repository was modified. Researchers found malware in two official PyPI wheels, and a Microsoft maintainer confirmed their removal. The confirmed malicious distribution warrants L4. A verified total of affected installations or stolen credentials is still unavailable.
The installed .pth files execute import statements during normal Python startup in the environment where they are installed. No Agent Framework import is needed, and starting pip can trigger the collector. Separate virtual environments are not automatically infected merely because they use the same Python executable. The payload reads accessible environment variables, credential files and other processes’ environments, attempts to obtain Azure managed-identity and Azure DevOps tokens, and in 1.26.2 also makes GitHub Actions OIDC requests. These requests require the corresponding identity, permissions or token-request variables; installing the package does not grant arbitrary cloud access. Static collection code does not prove successful token issuance, cloud access or completed exfiltration on a particular host. A detached child may outlive the job that started it, depending on runner and container cleanup.
The likely publishing-access compromise remains under investigation. Earlier StepSecurity text reported a newly created maintainer account. Its revised main analysis says the available evidence does not establish the specific account, credential, initial access vector or uploader identity, although an older flow summary on the same page retains the account claim. That identity claim remains unverified; Upwind also leaves the exact credential route unresolved. Do not infer a wider Microsoft compromise or an attacker identity from those observations. Endor’s initial report still describes 1.26.2 as latest, but the later Microsoft confirmation and current PyPI metadata establish that both malicious releases were removed. That does not clean installed environments or prove the publishing access has been revoked.
Published malicious SHA-256 indicators are listed in full. The clean 1.26.0 initializer shares its hash with the restored initializer in malicious 1.26.2, so that clean file alone cannot clear an environment.
November 19 follow-up: Wiz’s November 18 update assesses that a client certificate and private key for Microsoft’s Engineering System Release Pipeline (ESRP) were compromised. It reports a rejected publishing attempt from AWS followed by success from Microsoft-owned IP space; neither location identifies the actor. Initial credential theft and Microsoft confirmation of this assessment remain unresolved. Wiz’s single-source analysis of 50 captured requests separates four attacker-side requests, 29 apparent sandboxes/scans/tests and 17 requests representing three victim exfiltration cases. This is not an independently verified or exhaustive victim total: collection was limited and later requests could be rejected. The existing cleanup, rollback and credential-response steps still apply.
| Artifact | SHA-256 |
|---|---|
| agent_framework-1.26.1-py3-none-any.whl | d27fa34414e6201d5e03e559ef634f020057554d7b3f4898dd5d7cd3e989e110 |
| agent_framework_meta.pth | 21f28e8517a10ffe431f8d68f5875c85eca4001ae6d118322b0a41873998eb5e |
| agent_framework_meta/init.py in 1.26.1 | c275ccbe520ef3c0f02dc6a35389e427f9f1b4e0b12e140cd7bf7179ce143f02 |
| agent_framework_meta/_telemetry.py | 39fa329f2a93f734b0bb8f5adb203ea3331d1ae479832a5015a54cb17aabd663 |
| agent_framework-1.26.2-py3-none-any.whl | 3d20a8bc91351a9a16b6db243b848ceca0206b7a8623b02d2af553a9c9f7e0a9 |
| af_runtime_diag.pth | 325e7e9f0ec94e41ad1a1b7a3f18a6b8b5bffece2e2b97b8d3369eb967452f93 |
| af_runtime_diag.py | 54d885b7d7161c9ed96489c66364c4bfbf635929166843bba10d97d46b5a2e1f |
Fixed versions
| Product | Safe from | Note |
|---|---|---|
| agent-framework | 1.26.0 | Known-clean rollback; not a newer patch |
Crime-scene timeline
Nov 12, 2026
Clean 1.26.0 release published
Nov 17, 20:35:20 UTC
Malicious 1.26.1 wheel published
A .pth hook loads a credential collector when Python starts in the affected environment.
Nov 17, 21:08:39 UTC
Malicious 1.26.2 appears after the first version was removed
The new layout restores the normal package initializer and moves the startup payload to af_runtime_diag.py; GitHub Actions OIDC collection is added.
Nov 17, 21:35 UTC
Researcher reports both versions removed
The issue's status update says PyPI is back to 1.26.0; a Microsoft maintainer also confirms removal. Cached wheels and mirrors can still distribute the malware.
Nov 18, 2026
Revised analysis leaves the publishing identity unconfirmed
StepSecurity's revised main analysis does not establish the account, credential or initial access vector. An older flow summary on the same page still carries the account claim; it is not a verified identity finding.
Nov 18, 14:00 UTC
Wiz assesses an ESRP credential path and analyzes captured uploads
Its investigation points to a client certificate/private key and identifies three distinct cases of victim-data exfiltration in the captured sample, not a complete victim count.
Who said what
We list each claim and who made it. Primary sources (the vendor, the researcher, the registry) are marked. Where reports disagree, we grade by the worst credible case.
- Upwind original report and Microsoft maintainer confirmationPrimaryRecords publication times, both payloads, hook-first cleanup, cache/artifact risks and a Microsoft maintainer's confirmation that both releases were removed. The precise publishing credential remains unconfirmed.
- Endor Labs artifact analysisPrimaryAnalyzes both wheels, startup execution, identity requests, seven malicious artifact hashes and safe containment. Its initial latest-version status predates the later removal confirmation.
- StepSecurity static analysisPrimaryAnalyzes the wheels; its revised main text leaves the account and credential unestablished, while an older flow summary retains the earlier account claim. Re-publication after the first removal does not establish current access.
- PyPI agent-framework release metadataPrimaryAt the November 18 check the latest release is 1.26.0, its wheel hash matches the known-clean artifact, and 1.26.1/1.26.2 are absent from the release map.
- Wiz original investigation and November 18 updatePrimaryAssesses the ESRP publishing path and analyzes captured uploads; does not establish initial credential theft or a global victim total.