The Second Coming: How "Shai-Hulud 2.0" Unleashed a New Worm on the Developer Ecosystem

The Second Coming: How "Shai-Hulud 2.0" Unleashed a New Worm on the Developer Ecosystem

The Second Coming: How "Shai-Hulud 2.0" Unleashed a New Worm on the Developer Ecosystem

The Second Coming: How "Shai-Hulud 2.0" Unleashed a New Worm on the Developer Ecosystem

How Shai-Hulud 2.0 ran during npm installs, hid behind the Bun runtime, leaked secrets to public GitHub repos, and what to rotate and audit now.

François-Henri Champagne

A new level of aggression
Shai-Hulud is back, and it moves faster. In late November 2025, the supply chain campaign its creators call “The Second Coming” compromised hundreds of npm packages. Within days, over 25,000 GitHub repositories held its stolen secrets. The first wave, in September, had already stolen developers’ npm and GitHub tokens and used them to spread.

Hijacking the build process
Shai-Hulud 2.0 runs during installation. Most malware waits for someone to launch it. This one hides in trusted or lookalike npm packages and abuses the preinstall lifecycle script, so the malicious code executes as soon as a developer starts installing the package. It runs even if the install fails.

Evasion via Bun
The attackers got past security scanners by switching runtimes. Most security tools watch Node.js closely, so the malware installs the Bun runtime and runs there instead. Out of their view, it scrapes environment variables, SSH keys and cloud credentials (AWS, Azure, GCP).

Hiding data in plain sight
The stolen secrets went to public GitHub repositories, with no hidden collection server. The attackers labeled each repository “Sha1-Hulud: The Second Coming.” Their exfiltration blended in with legitimate GitHub traffic, which made it much harder to detect.

Worm-like spread
The malware used the stolen credentials to spread. It published new malicious npm packages on its own. It also registered infected machines as self-hosted GitHub runners, so each victim environment became a base for further attacks.

Immediate action required
Security experts warn that any organization using npm should assume it is exposed. The breach put thousands of valid secrets in the open. Start by rotating all development secrets. Then audit your GitHub runners for unauthorized additions and check your dependency manifests line by line.

Catch the next trusted tool that turns

Shai-Hulud spread through code people trusted. Browser extensions are trusted code too, and they run on every laptop. Ostral watches each one in your fleet and flags the update that turns it malicious.