Security researchers this week disclosed an npm supply-chain attack affecting more than 400 packages, including projects connected to Keyv and
The post The npm attack that turned provenance attestations into camouflage appeared first on The New Stack.
Security researchers this week disclosed an npm supply-chain attack affecting more than 400 packages, including projects connected to Keyv and Cacheable. The attackers used stolen developer credentials to publish malicious versions.
This incident appears to point to a trend in software security: Attackers are going after the developers and workflows already trusted to publish.
Worm spreads through credentialsAttackers are going after the developers and workflows already trusted to publish.
According to Microsoft Threat Intelligence, the malicious releases contained a variant of the Mini Shai-Hulud credential-stealing worm as they bypassed source repositories as they spread, and began with stolen maintainer credentials. Once inside, the worm searched developer machines and CI environments for any other credentials it could use.
When it found an active npm publishing token, it downloaded the latest version of every package the account could access, injected a malicious preinstall lifecycle hook, bumped the patch number and published the infected versions. Because npm runs preinstall hooks automatically before installation finishes, the malware could start running on developer workstations and CI runners before application tests or security checks began.
Preinstall hooks enable silent executionBecause npm runs preinstall hooks automatically before installation finishes, the malware could start running on developer workstations and CI runners before application tests or security checks began.
In CI environments, it stayed connected to the active job, where it could reach workflow secrets, runner credentials, and publishing permissions. On workstations, it could continue running in the background and inject startup files into Visual Studio Code and Claude, including .vscode/tasks.json and .claude/settings.json.
The attack exposed a weakness in trusted publishing, highlighting that malware running inside an authorized workflow can request its own short-lived token instead of stealing a long-lived publishing credential. The resulting malicious package can even carry valid provenance attestations.
Provenance doesn’t guarantee integrityThis campaign shows how quickly an attack can move from a developer’s machine into the rest of the release process. Shared CI systems add another opening because GitHub Actions can reuse dependencies across workflow runs. GitHub’s documentation warns that those cached files are not signed or verified.
The lesson for engineering teams is to keep publishing access away from the parts of the pipeline that install dependencies. The principle of restricting what automated processes can do echoes a bigger trend in how the industry is rethinking blanket permissions for AI-assisted coding.
Isolate publishing from dependency installationThis campaign shows how quickly an attack can move from a developer’s machine into the rest of the release process.
Microsoft recommends upgrading to npm CLI 12, pinning known-good versions and using min-release-age to give teams time to review new releases before they are installed.
Rotating the stolen token may not be enough once a compromised package has run its lifecycle scripts. Teams may also need to rebuild affected machines and base images, clear shared caches and recreate software artifacts from trusted dependencies.
Group Created with Sketch.
| # | Наименование новости | Тональность | Информативность | Дата публикации |
|---|---|---|---|---|
| 1 | Червь ChainDrop поразил более 400 NPM-пакетов | 0 | 22.92 | 04-08-2026 |
| 2 | Red Hat npm Package Compromise Highlights a Growing Supply Chain Problem | -2 | 7 | 02-06-2026 |
| 3 | 140+ Malicious npm Packages Turned Web Proxies for Students Into a DDoS Botnet | -2 | 7 | 14-07-2026 |
| 4 | GitHub Actions Compromise CI/CD Supply Chain Risks Explored | 0 | 8 | 26-05-2026 |
| 5 | Атака, которая выглядит как обычная работа ИИ-агента. На что охотится новый червь в NPM-инфраструктуре разработчиков | 0 | 14.63 | 22-07-2026 |
| 6 | Mini Shai-Hulud: Where SLSA’s Boundaries Fall | 0 | 7 | 10-06-2026 |
| 7 | Massive supply-chain attack compromises 440 packages under four hours | 0 | 18.58 | 04-08-2026 |
| 8 | Spy agencies say AI can help combat AI cyber risks. But don’t forget the basics | 0 | 6 | 24-06-2026 |
| 9 | New GitHub Zero-Day Exposed Developer Tokens to Attackers | -5 | 7 | 04-06-2026 |