# Report: Microsoft agent-framework 1.26.1 and 1.26.2 on PyPI Shipped a Credential Stealer. Pin 1.26.0 and Rotate From a Clean Machine

Two malicious releases of Microsoft's agent-framework Python package, 1.26.1 and 1.26.2, went out 33 minutes apart on 17 November and ran a credential stealer on every Python launch, The Hacker News reports, citing eight security firms. Pin 1.26.0, rebuild from clean and rotate credentials from a machine that never installed them.

By Neomanex. Updated 2026-11-24.

## The verdict

If any environment of yours pulled **Microsoft Agent Framework** (`agent-framework` on PyPI) on 17 November 2026, treat it as compromised. Pin **1.26.0**. Uninstalling 1.26.1 or 1.26.2 is not enough: the payload runs on every Python start, and some of the tokens it takes are freshly issued, so rotating your stored secrets does not cover them.

Affected: `agent-framework` 1.26.1 and 1.26.2 (not listed in our directory). Safe pin: 1.26.0.

## What happened

The Hacker News (published 18 November, updated 20 November with Microsoft's response) reports, citing Aikido, Chainguard, Endor Labs, OX Security, SafeDep, Socket, StepSecurity and Wiz:

- **Two releases, 33 minutes apart.** "The malicious versions, 1.26.1 and 1.26.2, were published 33 minutes apart on November 17, 2026." THN puts the exposure window "between 8:35 and roughly 9:20 p.m. UTC on November 17, 2026".
- **Runs without an import.** Per Endor Labs, "each wheel adds a .pth file to site-packages", so "the stealer runs on any Python launch in an affected environment, including pip itself". THN names the files: `agent_framework_meta.pth` in 1.26.1 and `af_runtime_diag.pth` in 1.26.2.
- **What it takes.** Azure CLI files (`~/.azure/*.json`), npm, pip, Git, Docker and Hugging Face config, credential-like environment variables, plus Azure DevOps OIDC and managed-identity tokens. 1.26.2 adds GitHub Actions OIDC tokens.
- **Why rotation alone fails.** SafeDep: "Besides reading credentials already on disk, the code asks the platform to issue new ones. Rotating stored secrets does not cover those."
- **Exfiltration.** The haul is packed into JSON, zlib-compressed, Base64-encoded and sent by HTTPS POST to `webhook[.]site/d381fd80-ec62-42ad-8f5c-d1b15103c9bb`.
- **Reach.** The package sees about 190,000 downloads a month.
- **Microsoft's response.** "We have made some repositories private while we investigate malicious content. Our priority is to protect customers and the broader ecosystem." THN reports `microsoft/agent-framework` and `microsoft/onnxruntime` were among them.

## Why it matters

This is the worst shape a supply chain hit can take for an agent stack. Agent code usually runs on CI runners and dev boxes that hold cloud identities, and a `.pth` hook fires before your code does, on any interpreter start. Short window, but CI pipelines that float to the latest release would have pulled it automatically.

The OIDC detail is the part most incident playbooks will miss. Rotating keys in a vault does nothing about tokens the platform minted for the attacker on request. You need to look at what those identities did, not only what they stored.

**What we have not verified.** We did not read a Microsoft advisory or any of the eight firms' own posts, and we have not inspected the wheels. Every figure here is as THN reports it.

## What changes for you

1. **Scope.** List every environment and CI runner that installed or upgraded `agent-framework` on 17 November. Isolate them.
2. **Rebuild, then pin.** Rebuild from clean images and pin `agent-framework==1.26.0`. Do not trust an in-place uninstall.
3. **Rotate from a clean machine.** Azure, npm, pip, Git, Docker and Hugging Face credentials, done from a host that never ran the bad versions.
4. **Audit identities.** Check Azure managed identities and sign-in logs, and review GitHub Actions workflows and OIDC trust for activity in and after the window.
5. **Hunt the endpoint.** Search proxy and DNS logs for the `webhook[.]site` path above.

## FAQ

**Is 1.26.0 safe?**
THN names 1.26.0 as the version to pin. The malicious releases are 1.26.1 and 1.26.2.

**I uninstalled the bad version. Am I done?**
No. Rebuild the environment from clean and rotate credentials from a clean machine, then audit OIDC and managed-identity activity, because those tokens were issued fresh and are not fixed by rotation.

**Did I need to import agent-framework to be hit?**
No. The `.pth` file runs on any Python launch in the affected environment, including pip itself.

Canonical: https://neomanex.com/news/microsoft-agent-framework-pypi-1-26-1-1-26-2-credential-stealer-pin-1-26-0
