Armando found that @ctrl/ngx-codemirror v7.0.1, an Angular component wrapping the CodeMirror code editor with 7,190,651 downloads, was backdoored on September 15, 2025. The malicious release injects a worm payload that fires automatically at npm install time and exfiltrates AWS, GCP, and ECS cloud credentials to an attacker-controlled endpoint. With over 7 million downloads, this is among the highest-impact packages in the coordinated @ctrl worm wave.
Key Findings
- Malicious version: v7.0.1, published 2025-09-15; v7.0.0 is clean
- Entry point: postinstall lifecycle hook fires automatically on npm install
- Targets: developer machines and CI/CD pipelines running Angular projects; harvests AWS, GCP, and ECS metadata credentials
- Detection: Script-JS.Worm.SupplyChain, Text.Worm.SupplyChain
Package Background
@ctrl/ngx-codemirror is an Angular wrapper for the CodeMirror in-browser code editor, first published in 2018. With 7,190,651 total downloads and widespread use in Angular development environments and developer tooling products, it is among the most impactful targets in the @ctrl namespace attack wave. The malicious v7.0.1 was published at 19:52 UTC on September 15, 2025 -- simultaneously with multiple other @ctrl packages compromised in the same operation.
Attack Analysis
Two file changes separate v7.0.1 from the clean v7.0.0: a new bundle.js was added and package.json was modified to add a postinstall lifecycle hook. When a developer or CI/CD pipeline runs npm install, Node.js executes bundle.js automatically, requiring no user interaction.
The bundle.js payload -- SHA256 46faab8ab153fae6e80e7cca38eab363075bb524edd79e42269217a083628f09 -- is the same worm payload Armando identified across the entire @ctrl wave published simultaneously on September 15, 2025. It is a 3.5 MB minified JavaScript bundle embedding the AWS SDK v3, Octokit GitHub API client, and credential harvesting routines targeting the AWS Instance Metadata Service (IMDS) at 169.254.169.254, the GCP Metadata server at metadata.google.internal, and the AWS ECS Task Metadata endpoint at 169.254.170.2. Collected credentials are exfiltrated to https://webhook.site/bb8ca5f6-4175-45d2-b042-fc9ebb8170b7. The bundled npm registry client enables worm self-propagation.
The scale matters here: @ctrl/ngx-codemirror is used in Angular development workflows and developer portal products. Any organization running Angular apps that include this package in their build toolchain could have had their CI/CD cloud credentials stolen.