<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/chaindrop-the-npm-worm-that-turns-your-editor-against-you-5yjixhgpg" -->

---
title: ChainDrop: The npm Worm That Turns Your Editor Against You
description: ChainDrop is a supply-chain worm targeting the npm ecosystem, compromising 444 packages including keyv, flat-cache, cacheable-request, and cache-manager —...
canonical: https://daily.dev/posts/chaindrop-the-npm-worm-that-turns-your-editor-against-you-5yjixhgpg
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: ChainDrop: The npm Worm That Turns Your Editor Against You | daily.dev
og:description: ChainDrop is a supply-chain worm targeting the npm ecosystem, compromising 444 packages including keyv, flat-cache, cacheable-request, and cache-manager —...
og:url: https://daily.dev/posts/chaindrop-the-npm-worm-that-turns-your-editor-against-you-5yjixhgpg
og:image: https://api.daily.dev/og/posts/5YJiXHGPg.png
og:image:alt: ChainDrop: The npm Worm That Turns Your Editor Against You
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# ChainDrop: The npm Worm That Turns Your Editor Against You

**[Collections](https://daily.dev/sources/collections)** · 2 min read · 6 upvotes · 2 comments

## Summary

ChainDrop is a supply-chain worm targeting the npm ecosystem, compromising 444 packages including keyv, flat-cache, cacheable-request, and cache-manager — collectively downloaded around 2 billion times per month. Unlike earlier worms in the Shai-Hulud family, it propagates through rebuilt tarballs rather than source commits, making it invisible in git history. Once installed, it harvests npm tokens, GitHub credentials, cloud keys, Kubernetes and Vault secrets, and OIDC tokens from GitHub Actions runners. Most notably, it plants malicious hooks in .claude/settings.json and .vscode/tasks.json, which fire automatically when a developer opens an infected branch in VS Code or starts a Claude Code session — no user interaction required.

## Content

A new supply-chain worm called ChainDrop has been quietly working its way through the npm ecosystem, and it's a genuinely nasty piece of engineering. It's a variant of the Shai-Hulud worm family, and it managed to compromise 444 npm packages — including heavily-used dependencies like `keyv`, `flat-cache`, `cacheable-request`, and `cache-manager` — that together rack up something like 2 billion downloads a month. That's not a niche incident. That's deep in the plumbing of the JavaScript ecosystem.

What makes ChainDrop different from earlier worms in this family is *how* it spreads. Previous attacks left commits in source repositories, which meant you could at least find them if you went looking. ChainDrop skips that step entirely and propagates through rebuilt tarballs instead. The published package doesn't match anything in the git history. As far as your repo is concerned, nothing happened. That's a genuinely uncomfortable property for a worm to have.

## How it actually works

Once it lands, ChainDrop scans for npm tokens, GitHub credentials, cloud keys, and — depending on the environment — Kubernetes and Vault secrets too. In CI/CD pipelines, it's also been observed pulling OIDC tokens straight out of GitHub Actions runner memory.

Here's the part that got my attention: it plants malicious hooks in `.claude/settings.json` and `.vscode/tasks.json`. These aren't obscure files. They're config files that developers routinely commit to branches without a second thought. When a developer opens an infected branch in VS Code (via `folderOpen`) or starts a Claude Code session (via `SessionStart`), the hook fires automatically. No click, no approval, no

## Questions this post answers

### What is the ChainDrop npm worm and which packages does it affect?

ChainDrop is a supply-chain worm in the Shai-Hulud family that compromised 444 npm packages, including keyv, flat-cache, cacheable-request, and cache-manager — packages with roughly 2 billion combined monthly downloads. It spreads via rebuilt tarballs rather than source commits, so infected packages show no changes in git history. It steals npm tokens, GitHub credentials, cloud keys, Kubernetes and Vault secrets, and OIDC tokens from GitHub Actions runners.

_Developers maintaining JavaScript dependencies track npm supply-chain incidents like this on daily.dev._

### How does ChainDrop hide itself from git history in npm packages?

ChainDrop propagates through rebuilt tarballs rather than committing to source repositories. The published package on npm does not match anything in the git history, so standard source-code auditing and commit inspection will not reveal the infection. This is a deliberate departure from earlier Shai-Hulud family worms, which left detectable commits in repos.

_Teams auditing npm packages for supply-chain risks follow developments like this on daily.dev._

### How does ChainDrop use VS Code and Claude Code config files to execute malicious code?

ChainDrop plants malicious hooks in .vscode/tasks.json and .claude/settings.json. These hooks fire automatically — without any user click or approval — when a developer opens an infected branch in VS Code via the folderOpen event, or starts a Claude Code session via the SessionStart event. Because developers routinely commit these config files to branches, the attack surface is broad and the trigger is silent.

_Developers using AI coding tools and VS Code on shared repos watch for threats like this on daily.dev._

## Community discussion

Top comments from developers on daily.dev.

**@codechini** · 1 upvotes

> It sure is "genuinely nasty piece of engineering.".

**@akkitto** · 0 upvotes

> You have to check, what you commit... I would never commit any of the mentioned files without looking twice. They are barely ever changed.

---

Tags: [#security](https://daily.dev/tags/security), [#javascript](https://daily.dev/tags/javascript), [#cicd](https://daily.dev/tags/cicd), [#malware](https://daily.dev/tags/malware), [#npm](https://daily.dev/tags/npm)

[View this post on daily.dev](https://daily.dev/posts/chaindrop-the-npm-worm-that-turns-your-editor-against-you-5yjixhgpg)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"ChainDrop: The npm Worm That Turns Your Editor Against You","url":"https://daily.dev/posts/chaindrop-the-npm-worm-that-turns-your-editor-against-you-5yjixhgpg","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/chaindrop-the-npm-worm-that-turns-your-editor-against-you-5yjixhgpg"},"datePublished":"2026-08-21T23:12:49.315Z","dateModified":"2026-08-21T23:13:33.462Z","description":"ChainDrop is a supply-chain worm targeting the npm ecosystem, compromising 444 packages including keyv, flat-cache, cacheable-request, and cache-manager —...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/0a35ea66fde8485f2a3800fa77f6baa6?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/0a35ea66fde8485f2a3800fa77f6baa6?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"Collections","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Collections","logo":"https://media.daily.dev/image/upload/s--fk_6ycEi--/f_auto,q_auto/v1780996001/logos/collections?_a=BAMAMiWQ0","url":"https://daily.dev/sources/collections"},"commentCount":2,"discussionUrl":"https://daily.dev/posts/chaindrop-the-npm-worm-that-turns-your-editor-against-you-5yjixhgpg","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":6},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":2}],"keywords":"security,javascript,cicd,malware,npm","timeRequired":"PT2M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Collections","item":"https://daily.dev/sources/collections"},{"@type":"ListItem","position":3,"name":"ChainDrop: The npm Worm That Turns Your Editor Against You"}]}
{"@context":"https://schema.org","@type":"WebPage","@id":"https://daily.dev/posts/chaindrop-the-npm-worm-that-turns-your-editor-against-you-5yjixhgpg","comment":[{"@type":"Comment","text":"It sure is “genuinely nasty piece of engineering.”.","datePublished":"2026-08-22T03:17:58.065Z","url":"https://daily.dev/posts/5YJiXHGPg#c-oQDlNLOIy","author":{"@type":"Person","name":"Chinmay","url":"https://daily.dev/codechini","image":"https://lh3.googleusercontent.com/a/ACg8ocIH2WsF8sgGFUn2cqwWEP7lShdb0sJtMm77hIQNvoUXN83IWMIo=s96-c"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":1}},{"@type":"Comment","text":"You have to check, what you commit… I would never commit any of the mentioned files without looking twice. They are barely ever changed.","datePublished":"2026-08-22T18:35:50.348Z","url":"https://daily.dev/posts/5YJiXHGPg#c-5eIVGtTKO","author":{"@type":"Person","name":"Daniel","url":"https://daily.dev/akkitto","image":"https://media.daily.dev/image/upload/s--FtwJqX4c--/f_auto/v1754900041/avatars/avatar_29TCpY2hJR72V3BlxPXzX?_a=BAMClqZW0"}}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/chaindrop-the-npm-worm-that-turns-your-editor-against-you-5yjixhgpg#faq","mainEntity":[{"@type":"Question","name":"What is the ChainDrop npm worm and which packages does it affect?","acceptedAnswer":{"@type":"Answer","text":"ChainDrop is a supply-chain worm in the Shai-Hulud family that compromised 444 npm packages, including keyv, flat-cache, cacheable-request, and cache-manager — packages with roughly 2 billion combined monthly downloads. It spreads via rebuilt tarballs rather than source commits, so infected packages show no changes in git history. It steals npm tokens, GitHub credentials, cloud keys, Kubernetes and Vault secrets, and OIDC tokens from GitHub Actions runners. Developers maintaining JavaScript dependencies track npm supply-chain incidents like this on daily.dev."}},{"@type":"Question","name":"How does ChainDrop hide itself from git history in npm packages?","acceptedAnswer":{"@type":"Answer","text":"ChainDrop propagates through rebuilt tarballs rather than committing to source repositories. The published package on npm does not match anything in the git history, so standard source-code auditing and commit inspection will not reveal the infection. This is a deliberate departure from earlier Shai-Hulud family worms, which left detectable commits in repos. Teams auditing npm packages for supply-chain risks follow developments like this on daily.dev."}},{"@type":"Question","name":"How does ChainDrop use VS Code and Claude Code config files to execute malicious code?","acceptedAnswer":{"@type":"Answer","text":"ChainDrop plants malicious hooks in .vscode/tasks.json and .claude/settings.json. These hooks fire automatically — without any user click or approval — when a developer opens an infected branch in VS Code via the folderOpen event, or starts a Claude Code session via the SessionStart event. Because developers routinely commit these config files to branches, the attack surface is broad and the trigger is silent. Developers using AI coding tools and VS Code on shared repos watch for threats like this on daily.dev."}}]}
```

