Developers who installed agent-framework versions 1.26.1 or 1.26.2 should isolate affected environments before launching Python or pip. Both releases of Microsoft’s official AI-agent Python package carried credential-stealing code. The last clean release identified by researchers is 1.26.0, published November 12, 2026. Rebuilding the environment and addressing potentially exposed credentials are both necessary, according to StepSecurity’s analysis.
The malicious releases appeared on PyPI on November 17, 2026, at 20:35 and 21:08 UTC. Their startup hooks could execute before a developer’s script began, collecting secrets without an explicit Agent Framework import. Azure identities, Azure DevOps pipelines and, in the second release, GitHub Actions federation tokens were among the targets.
The immediate security boundary is therefore the affected Python environment and the credentials it could access, not whether an application actually used the framework.
Two Malicious Releases Arrived in 33 Minutes
Microsoft’s agent-framework package is an umbrella package that installs the components used to build and orchestrate AI agents. The compromised releases were uploaded to that official PyPI project, making this a supply-chain compromise of the legitimate package.
StepSecurity reports the following timeline:
| Event | Time, UTC, November 17, 2026 |
|---|---|
Malicious 1.26.1 uploaded | 20:35:20 |
1.26.1 quarantined | 21:06:16 |
Malicious 1.26.2 uploaded | 21:08:39 |
1.26.2 quarantined | 21:16:44 |
The second upload came two minutes and 23 seconds after the first quarantine. That sequence shows that quarantining the first release had not yet prevented another malicious publication. It does not reveal whether the attacker retained access afterward.
Elastic says its supply-chain monitor flagged 1.26.1 at 20:41 UTC, six minutes after publication. Its separate analysis also describes the startup hook and credential collection. That detection timing is Elastic’s reported result.

A November 18 update to Wiz’s investigation adds a possible publishing mechanism: researchers say the attacker appears to have compromised a client certificate and private key for Microsoft’s Engineering System Release Pipeline, or ESRP. Wiz reports that an initial attempt from AWS was rejected by IP filtering, while a subsequent attempt from Microsoft-owned IP space succeeded.
That is Wiz’s assessment of observed attacker activity. How those credentials were obtained and the attacker’s identity remain unknown.
Why “We Never Imported It” Is Not Enough
Both malicious releases placed a .pth file in the environment’s site-packages directory. During normal startup, Python’s site initialization processes these files, including executable lines beginning with import.
Version 1.26.1 used this line in agent_framework_meta.pth, as documented by Socket:
import agent_framework_meta
That line imported the package initializer, which then started the malicious _telemetry module. It is shown here to explain the trigger, not as a command to run.
The collector attempted to fork into a detached process. Where forking was unavailable, it used a background daemon thread. Errors were suppressed, and an _AF_TEL environment variable limited repeated execution within the same process tree. A fresh process tree could trigger collection again.
An ordinary Python-backed tool could therefore activate the stealer before its own work began. This is why running pip to investigate or uninstall the package inside a suspect environment is a poor first step: that action can itself start Python.
The hook operates when Python processes the affected environment’s site-packages; it does not automatically infect every virtual environment on the machine. Its collection scope can still reach beyond that environment when the running account can read other files or process environments.
The Second Release Changed What Defenders Must Search For
Version 1.26.2 moved the payload and restored the legitimate package initializer. That makes an investigation focused only on the first release’s modified __init__.py incomplete.
Wiz and Socket identify these two execution paths:
| Release | Startup hook | Payload location |
|---|---|---|
1.26.1 | agent_framework_meta.pth | agent_framework_meta/_telemetry.py, started through the package initializer |
1.26.2 | af_runtime_diag.pth | Top-level af_runtime_diag.py |
In 1.26.2, the new hook imported af_runtime_diag directly. A clean-looking agent_framework_meta/__init__.py was therefore compatible with a compromised installation.
My practical takeaway is to search for both hook names and both payload layouts. A detection written immediately after the first release could miss the second if it checks only the original files. The evidence supports that specific detection gap; it does not justify assuming that every Agent Framework component package was compromised.
What the Credential Stealer Collected
The payload combined local secret collection with attempts to obtain fresh identity tokens. Researchers describe several collection routes:
- Environment variables: Names containing credential-related strings such as
TOKEN,SECRET,PASSWORD,KEY,AZURE,AWS,GITHUBandOPENAI. - Other processes: On Linux, reads from up to 300
/proc/*/environfiles, subject to access permissions. - Credential and configuration files: Azure CLI data, pip configuration,
.npmrc,.netrc,.git-credentials, Docker configuration, Hugging Face tokens and Azure DevOps agent credentials. - Application files: Selected
.envand JSON files under locations including/appand/workspace. - Cloud identity endpoints: Requests to Azure managed-identity and Azure DevOps OIDC endpoints, plus GitHub Actions OIDC requests in
1.26.2.
These targets are documented in the StepSecurity analysis and Socket’s payload breakdown.
The identity-token requests matter because a workflow can be exposed without storing a long-lived Azure password. In GitHub Actions workflows with id-token: write, version 1.26.2 requested tokens for api://AzureADTokenExchange and https://management.azure.com/. Where an Entra ID federated credential trusts the workflow, suitable tokens can be exchanged for Azure access, Wiz explains.
Token-request code is not proof that every request produced usable cloud access. Elastic notes that the Azure DevOps requests omitted the documented serviceConnectionId parameter, leaving uncertainty about whether the resulting tokens would match a configured federated credential.
Collected data was serialized as JSON, compressed with zlib, Base64-encoded and sent by HTTPS POST to one hardcoded endpoint. Encoding did not provide additional encryption beyond HTTPS.
Immediate Remediation and Indicators
Frequently Asked Questions
3 questions
1Can the stealer run without importing Agent Framework?
Yes. Its .pth hook could execute during normal Python startup when Python processed the affected environment’s installed packages.