Key details

  1. Affected PyPI distribution: agent-framework, versions 1.26.1 and 1.26.2, released November 17, 2026.
  2. Both releases quarantined; 1.26.0 reported as latest clean version at the time of research.
  3. Malware executes via .pth Python startup processing without requiring an explicit agent-framework import.
  4. Targets include environment variables, Azure identities, Azure DevOps and GitHub Actions OIDC tokens, and local credentials for other services.
  5. Researchers published wheel hashes and a webhook.site network indicator; check direct primary report for exact IOCs.

What builders should take away

  1. Inventory pinned and transitive agent-framework versions across workstations, CI and deployed images; identify whether Python ran after installation.
  2. Isolate and rebuild affected environments from trusted artefacts, then revoke or rotate secrets potentially reachable from those environments.
  3. Review egress, cloud audit and CI token-use logs; do not assume quarantining a package undoes credential exposure.
  4. Keep a verified-clean version pinned while awaiting authoritative Microsoft incident updates and publishing-access root cause.

What changed

On November 17, 2026, attackers published malicious versions 1.26.1 and 1.26.2 of Microsoft's official agent-framework distribution on PyPI. Socket's artifact analysis identified Python .pth startup hooks that ran credential-collection code when Python started, even without importing the package. The second malicious release changed the hook and added GitHub Actions OIDC collection. Both releases were quarantined; reporting identifies 1.26.0 as the last known clean release at the time of investigation. A Microsoft maintainer acknowledged the compromise and investigation, but the initial publisher-account intrusion mechanism remains unconfirmed.

Why it matters

A routine dependency install could expose cloud, CI/CD and AI-provider credentials from developer machines or build agents without breaking the legitimate application. Startup hooks mean import-based checks and successful smoke tests cannot rule out compromise. Replacing the wheel is necessary but not sufficient: tokens already exfiltrated may remain valid until revoked.

What the compromised releases did

Socket analysed the two PyPI wheels and documented different .pth startup paths: 1.26.1 used agent_framework_meta.pth and a telemetry-named collector, while 1.26.2 used af_runtime_diag.pth and af_runtime_diag.py. The collector inspected environment variables, configuration files and accessible process environments, and attempted to obtain Azure managed identity, Azure DevOps and, in 1.26.2, GitHub Actions OIDC credentials. It sent compressed, encoded data to a webhook.site destination. This is researcher-observed malicious functionality, not proof that every installation successfully exfiltrated data.

Affected scope and immediate response

Check lockfiles, installed distributions, build logs, container layers and CI caches for agent-framework 1.26.1 or 1.26.2. Treat environments that executed Python with either installed version as potentially compromised, including environments that never imported the framework. Isolate them, preserve relevant logs and artefacts for investigation, rebuild from known-clean images and pin to a verified clean release such as 1.26.0 pending Microsoft guidance. Rotate and revoke reachable API keys, cloud tokens, deployment credentials and CI federation trust where exposure is plausible. Examine outbound egress records for the reported webhook.site indicator; absence of a successful request is not a guarantee that no credentials were exposed.

What is confirmed and what is not

Socket's direct package analysis and separate security reporting agree on the affected versions, startup execution and credential targets. SecurityWeek reports that a Microsoft maintainer acknowledged removal and an ongoing investigation. The exact mechanism by which the attacker obtained publishing access, total download/install count of malicious wheels, successful exfiltration volume and victim impact have not been established. Do not confuse the approximately 190,000–200,000 monthly project downloads reported by news outlets with compromised installations.

Why this differs from a normal package vulnerability

This was malicious code introduced into official distribution artefacts, not merely a bug in the framework's normal functions. The .pth mechanism runs through Python site initialization, which can affect unrelated Python processes in the same environment. Version 1.26.2 moved the payload, so a detector that only checks the 1.26.1 filename can miss the second release. Supply-chain controls should include package provenance, hash/lock verification, constrained build identities, outbound network controls and short-lived scoped secrets.

What to watch next

  • Microsoft's authoritative incident postmortem and account/publishing compromise mechanism.
  • Any further malicious versions, additional exfiltration destinations or corrected affected-version scope.
  • Evidence of successful credential abuse and guidance on revoking federated CI identities.

Still unclear

  • Initial compromise vector for the PyPI publishing identity is not publicly established.
  • No verified victim count or successful exfiltration total.
  • Some environment-specific token acquisition attempts may fail; researchers demonstrated attempted collection rather than universal success.

Sources

Direct reading behind this dossier.

3 sources

Discussion

Discussion is reader-contributed. Comments are not part of the BTN dossier or its editorial evidence.

0 visible comments

Join the discussion

Keep comments useful and relevant. Reader contributions may be moderated and are not BTN editorial evidence.

Sign in to comment