[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"$fUwSu8qPRObkooGeHKr-VZcplM-vl5Nbn3I6c2QoIKa8":3},{"lesson":4},{"id":5,"slug":6,"article_id":7,"title":8,"body":9,"prevention":10,"framework_refs":11,"framework_notes":17,"status":23,"created_at":24,"published_at":25,"article":26,"tags":30,"podcasts":43,"controls":44},"9677f261-fba6-4990-826c-d0f813a51a7b","malicious-pypi-package-steals-azure-and-ci-credentials-via-supply-chain-attack","da43ec0d-3aaf-4171-9b2b-38608158aaca","Malicious PyPI Package Steals Azure and CI Credentials via Supply Chain Attack","Attackers published trojanized versions of the Microsoft agent-framework Python package to PyPI, embedding a credential stealer that silently harvested Azure tokens, OIDC tokens, and CI pipeline secrets from environment variables and credential files. This is a classic software supply chain attack where developers or automated pipelines unknowingly install a malicious dependency, granting attackers access to cloud infrastructure without any direct breach of target systems. The stolen credentials — particularly Azure DevOps and OIDC tokens — could enable lateral movement, privilege escalation, and full cloud account takeover. This incident highlights how unpinned or unverified dependencies in CI\u002FCD pipelines represent a critical and often underestimated attack surface. Rapid quarantine limited the blast radius, but any pipeline that consumed these versions before detection may already be compromised.","**Immediate actions:**\n- Audit all projects and CI\u002FCD pipelines for use of agent-framework versions 1.26.1 or 1.26.2 and downgrade or replace immediately.\n- Rotate all Azure tokens, OIDC tokens, DevOps credentials, and any secrets present in environments that consumed the affected versions.\n- Scan environment variables and credential files in affected build agents for signs of exfiltration to external webhook endpoints.\n\n**Long-term improvements:**\n- Pin all third-party dependencies to specific, verified checksums or hashes and enforce this policy via dependency lockfiles in every project.\n- Implement a private package registry or artifact proxy that vets and mirrors approved packages before they reach CI\u002FCD pipelines.\n- Restrict CI\u002FCD pipeline permissions to the minimum required scope and avoid persisting long-lived credentials in environment variables.\n\n**Detection measures:**\n- Deploy software composition analysis (SCA) tools in CI pipelines to flag newly published or recently modified package versions before installation.\n- Monitor outbound network traffic from build agents for unexpected connections to external services such as webhook.site or similar exfiltration endpoints.\n- Alert on anomalous access patterns for Azure and Azure DevOps tokens, including usage from unfamiliar IP addresses or at unusual times.",[12,13,14,15,16],"MITRE ATT&CK T1195.001: Supply Chain Compromise: Compromise Software Dependencies and Development Tools","MITRE ATT&CK T1552.001: Unsecured Credentials: Credentials In Files","CIS Control 16: Application Software Security (v8)","NIS2 Article 21(2)(d)","NIST SP 800-53 SA-12: Supply Chain Protection",{"NIS2 Article 21(2)(d)":18,"NIST SP 800-53 SA-12: Supply Chain Protection":19,"CIS Control 16: Application Software Security (v8)":20,"MITRE ATT&CK T1552.001: Unsecured Credentials: Credentials In Files":21,"MITRE ATT&CK T1195.001: Supply Chain Compromise: Compromise Software Dependencies and Development Tools":22},"NIS2 supply chain security obligations require entities to assess risks from third-party software dependencies, which would have mandated controls over PyPI package integrity.","SA-12 requires organizations to protect against supply chain threats by validating the integrity of software acquired from external sources, directly applicable to unsigned or unverified PyPI packages.","CIS Control 16 requires organizations to manage the security of software they use, including vetting third-party components, which would have flagged or blocked the malicious package versions.","The malware specifically targeted credential files and environment variables containing Azure and CI tokens, which is exactly what this technique covers.","This technique directly describes the method used — injecting malicious code into a widely used open-source package (agent-framework) to compromise downstream consumers.","published","2026-11-17T23:21:05.759494+00:00","2026-11-17T23:21:05.711+00:00",{"id":7,"url":27,"slug":28,"title":29},"https:\u002F\u002Fwww.wiz.io\u002Fblog\u002Fmalicious-version-of-microsofts-agent-framework-published-to-pypi","microsoft-agent-framework-compromised-credential-stealer-targets-azure-and-ci-pi-7dad0d","Microsoft agent-framework Compromised: Credential Stealer Targets Azure and CI Pipelines",[31,37],{"id":32,"name":33,"slug":34,"description":35,"color":36},"1ec88fde-2d0f-4ed8-932a-33f5ccc0fdc7","Access Control","access-control","Excessive privileges, missing MFA, weak auth","#f97316",{"id":38,"name":39,"slug":40,"description":41,"color":42},"f0c2a0af-58aa-4128-87c9-6acd30f2dc48","Supply Chain","supply-chain","Third-party risk, compromised dependencies","#8b5cf6",[],[45,49,53],{"slug":46,"name":47,"problem":48},"secrets-management","Secrets management","API keys, tokens and passwords stop leaking from code, chat and configuration files.",{"slug":50,"name":51,"problem":52},"endpoint-detection-response","Endpoint detection and response (EDR and XDR)","Malware and hands-on-keyboard attackers on laptops and servers get spotted and stopped.",{"slug":54,"name":55,"problem":56},"software-supply-chain","Software supply chain security","Malicious and vulnerable open-source packages are caught before they ship."]