{"id":10447,"date":"2026-11-18T11:58:53","date_gmt":"2026-11-18T11:58:53","guid":{"rendered":"https:\/\/cybersecurityinfocus.com\/?p=10447"},"modified":"2026-11-18T11:58:53","modified_gmt":"2026-11-18T11:58:53","slug":"attackers-hijack-microsofts-agent-framework-package-to-steal-azure-and-ci-credentials","status":"publish","type":"post","link":"https:\/\/cybersecurityinfocus.com\/?p=10447","title":{"rendered":"Attackers hijack Microsoft\u2019s agent-framework package to steal Azure and CI credentials"},"content":{"rendered":"<div>\n<div class=\"grid grid--cols-10@md grid--cols-8@lg article-column \">\n<div class=\"col-12 col-10@md col-6@lg col-start-3@lg\">\n<div class=\"article-column__content\">\n<div class=\"container\"><\/div>\n<p class=\"wp-block-paragraph\">Attackers briefly hijacked Microsoft\u2019s official Agent Framework package on PyPI and used it to distribute credential-stealing malware capable of harvesting cloud tokens, developer secrets and CI\/CD credentials from developer workstations and automated build systems, according to multiple security researchers.<\/p>\n<p class=\"wp-block-paragraph\">Two malicious versions of the package, 1.26.1 and 1.26.2, appeared on PyPI on November 17 and stayed live for less than an hour.<\/p>\n<p class=\"wp-block-paragraph\">\u201cThe package is a credential stealer: it harvests environment secrets, cloud and package-manager credentials, and Azure managed identity tokens, then exfiltrates them to an attacker-controlled webhook,\u201d OX Security, one of several security firms that flagged the releases, said in a <a href=\"https:\/\/www.ox.security\/blog\/breaking-hijacked-releases-of-microsofts-official-agent-framework-steals-azure-and-ci-credentials\/\" target=\"_blank\" rel=\"noopener\">blog post<\/a>.<\/p>\n<p class=\"wp-block-paragraph\">The payload ran automatically every time Python started, even if no code imported the package, OX said. The malicious versions also installed the genuine framework code, so applications kept working, and the compromise was easy to miss. The package has 192,534 monthly downloads, according to the firm.<\/p>\n<p class=\"wp-block-paragraph\">Other security firms, including Aikido Security, Endor Labs, and SafeDep, published similar analyses of the attack.<\/p>\n<p class=\"wp-block-paragraph\">Microsoft has not said publicly how the attacker got access to publish the package. The company did not immediately respond to a request for comment.<\/p>\n<h2 class=\"wp-block-heading\">How the stealer worked<\/h2>\n<p class=\"wp-block-paragraph\">The stealer collected environment variables with names containing words such as TOKEN, SECRET, PASSWORD, KEY, AZURE, AWS, GITHUB, and OPENAI, OX said. It also read up to 60 credential files. These included Azure CLI settings, Git and Docker credentials, npm and pip configuration, Hugging Face tokens, Azure DevOps build agent credentials and application .env files. It pulled secrets from up to 300 other running processes as well.<\/p>\n<p class=\"wp-block-paragraph\">The stealer also asked for new tokens. Inside Azure DevOps pipelines, it requested an identity token that can be exchanged for Azure access, OX said in the blog post. It also requested managed identity tokens for Azure services, including Resource Manager, Microsoft Graph, Key Vault, Storage, Cognitive Services, AI Foundry, and Azure DevOps.<\/p>\n<p class=\"wp-block-paragraph\">Endor Labs said the attack was aimed mainly at automated build systems. \u201cDeveloper laptops are in scope, but the payload is written for CI runners and Azure workloads,\u201d the firm wrote in its <a href=\"https:\/\/www.endorlabs.com\/learn\/agent-framework-compromised-software-supply-chain-attack\" target=\"_blank\" rel=\"noopener\">analysis<\/a>.<\/p>\n<p class=\"wp-block-paragraph\">The code was disguised as diagnostics. It sat in a module named _telemetry.py and sent data with a user agent labeled \u201caf-runtime-diagnostics,\u201d OX said. The stolen data went to a webhook.site address as compressed, encoded JSON.<\/p>\n<p class=\"wp-block-paragraph\">The attacker did not stop after the first release. While OX was researching the malware, version 1.26.1 was reverted to the clean 1.26.0. The attacker then uploaded 1.26.2, which used a different file path for the same payload, the firm said.<\/p>\n<p class=\"wp-block-paragraph\">The first version went up at 20:35 UTC and the second at 21:08 UTC, according to <a href=\"https:\/\/www.aikido.dev\/blog\/two-malicious-agent-framework-releases-hit-pypi-in-33-minutes\" target=\"_blank\" rel=\"noopener\">Aikido Security<\/a>. Both were gone by about 21:20 UTC.<\/p>\n<p class=\"wp-block-paragraph\">\u201cThis attack isn\u2019t just a one-off exfiltration attempt, but a planned, live and coordinated effort to reach as many victims as they can, while still being able to bypass blocks and restrictions,\u201d OX said.<\/p>\n<p class=\"wp-block-paragraph\">OX said the attackers appear to have found a way to hijack the process that builds the package\u2019s wheel files. Endor Labs, in its analysis, said both malicious versions were uploaded as wheel files only, without the source code package that came with the clean release. Microsoft has not confirmed how the breach happened.<\/p>\n<p class=\"wp-block-paragraph\">The short window may not limit exposure. Any unpinned install during that time pulled in a malicious version, Endor Labs said. Container images, CI caches, and lockfiles built in the window could still contain it.<\/p>\n<h2 class=\"wp-block-heading\">AI pipelines in focus<\/h2>\n<p class=\"wp-block-paragraph\">OX said the attack shows how attackers are targeting the AI developer ecosystem and the CI pipelines behind it. The stealer\u2019s target list includes OpenAI and Hugging Face tokens and Azure AI Foundry access.<\/p>\n<p class=\"wp-block-paragraph\">It is also not the first time this year that attackers have compromised an official Microsoft Python package. In May, Endor Labs <a href=\"https:\/\/endorlabs.com\/learn\/trojanized-microsoft-sdk-durabletask-1-4-1-through-1-4-3-deliver-credential-stealing-malware\" target=\"_blank\" rel=\"noopener\">detected three trojanized versions<\/a> of durabletask, Microsoft\u2019s Python SDK for Azure Durable Functions. No researcher has linked the two attacks.<\/p>\n<h2 class=\"wp-block-heading\">What security teams should do<\/h2>\n<p class=\"wp-block-paragraph\">Removing the package does not undo the damage. \u201cRemoving the package stops future runs, but it doesn\u2019t undo anything that was already sent,\u201d Aikido said.<\/p>\n<p class=\"wp-block-paragraph\">OX advised teams to check all environments, CI images, and lockfiles for either version and remove it. Teams should look for agent_framework_meta.pth and agent_framework_meta\/_telemetry.py on hosts and build agents, the firm said. Version 1.26.2 used different files, af_runtime_diag.pth and af_runtime_diag.py, according to Aikido.<\/p>\n<p class=\"wp-block-paragraph\">If the package ran anywhere, every secret reachable from that host should be treated as compromised, OX said. The firm recommended rotating Azure service principal secrets, personal access tokens, and GitHub, npm, PyPI, NuGet, Docker, Hugging Face, and OpenAI tokens. OX also advised teams to review Azure sign-in and activity logs for use of managed identities and federated credentials from affected build agents. Ox recommended pinning the agent-framework to a verified Microsoft release with hash checking and blocking outbound traffic to webhook.site from build infrastructure.<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>","protected":false},"excerpt":{"rendered":"<p>Attackers briefly hijacked Microsoft\u2019s official Agent Framework package on PyPI and used it to distribute credential-stealing malware capable of harvesting cloud tokens, developer secrets and CI\/CD credentials from developer workstations and automated build systems, according to multiple security researchers. Two malicious versions of the package, 1.26.1 and 1.26.2, appeared on PyPI on November 17 and [&hellip;]<\/p>\n","protected":false},"author":0,"featured_media":10448,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-10447","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-education"],"_links":{"self":[{"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=\/wp\/v2\/posts\/10447"}],"collection":[{"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"replies":[{"embeddable":true,"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=10447"}],"version-history":[{"count":0,"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=\/wp\/v2\/posts\/10447\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=\/wp\/v2\/media\/10448"}],"wp:attachment":[{"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=10447"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=10447"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=10447"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}