tensorlake@0.5.144: Shai-Hulud Worm Holds GitHub Tokens
TL;DR · the short version
tensorlake@0.5.144, the npm SDK for Tensorlake, shipped a Shai-Hulud/ChainDrop-family worm (flagged by Socket and StepSecurity, 8 October 2026). A preinstall hook harvests GitHub, npm, cloud, Vault and SSH credentials, then republishes the victim's packages. It carries a valid npm provenance attestation and installs a gh-token-monitor that runs rm -rf on the home directory if the stolen GitHub token is revoked. Remediate in order: find it, remove the persistence BEFORE revoking, rotate all credentials, pin to 0.5.143.
The Shai-Hulud worm has a new host. tensorlake@0.5.144 — the npm SDK for Tensorlake’s AI agent and document-processing infrastructure — shipped with a credential-stealing, self-republishing payload, and this variant adds something the earlier waves didn’t: a dead-man’s switch that wipes your home directory if you revoke the token it stole.
This is a developing incident and the full picture is still being assembled, so we’ll keep the usual discipline: what is confirmed, what is reported or early, and then what a security leader should actually do — in the right order, because this time the order matters.
What is confirmed
- A malicious version shipped. tensorlake@0.5.144 carries a worm in the Shai-Hulud / ChainDrop family, flagged by Socket and StepSecurity on 8 October 2026. StepSecurity names 0.5.143 as the safe version to pin.
- How it runs. A preinstall hook executes
setup.mjs. The script detects CI and skips itself there — this one is aimed at developer laptops, not runners. It downloads the Bun runtime and uses it to execute an obfuscated payload of roughly 856 KB placed undertypescript/lib/. - What it takes. GitHub and npm tokens, cloud keys, Kubernetes and Vault secrets, SSH keys, saved browser logins, and the config files of AI coding tools — Claude, Cursor and Windsurf — which increasingly hold API keys of their own.
- How it spreads. With a stolen npm token it downloads the victim’s own packages, injects itself, bumps the version and republishes them. That is the Shai-Hulud signature: every infected maintainer becomes a new publisher.
- The hostage token. It installs a persistent “gh-token-monitor” service. If the stolen GitHub token is revoked, the service runs
rm -rfagainst the home directory. The first thing most people do after a credential theft is now the thing that destroys the machine. - It looked legitimate. Socket reports the release came through the repository’s own release workflow and therefore carries a valid npm provenance attestation. Provenance proves where a package was built, not that the source it was built from was clean.
What is reported or still early
- Initial access. Reporting describes the attacker gaining access to the tensorlake GitHub repository and introducing the code via verified maintainer commits and a direct file upload, with the npm publish following roughly 20 hours later. Treat the timeline as reported, not forensically final.
- Command and control. The C2 address is resolved through an attacker-controlled Ethereum wallet, a technique seen in earlier waves; the most recent transaction pointed at
iseekaigogo[.]com. Expect it to change. - Early-detection indicators. The
setup.mjspreinstall file is the clearest marker. Early triage has also pointed at aMath_Symbol.jsfile inside the package; we have not yet seen that filename independently confirmed by a published analysis, so treat it as a lead to check in the package’s file listing rather than a settled IOC. - Blast radius. How many downstream packages the worm has republished into is not yet known. The honest answer today is “more than tensorlake.”
The detail that should change your runbook: order of operations
Every incident playbook says revoke first. This variant is built to punish that. The gh-token-monitor service is persistence plus a tripwire: it polls the stolen GitHub token, and the moment the token stops working it wipes ~/. So the sequence has to be: find the implant → remove the persistence (and preserve evidence if you need it) → then revoke and rotate. Socket’s warning is blunt: removing the npm dependency does not remove the implant.
Useful next, if this was relevant to you
The wider point is the one we made about @subql two days ago and keyv before that: this is no longer a leaked-secret problem, it is a trust-and-blast-radius problem. A valid provenance attestation on a malicious release is the proof.
The defender’s playbook
- ☐ Find it.
npm ls tensorlakeon every repo and developer machine; greppackage-lock.json,pnpm-lock.yamlandyarn.lockfor0.5.144. Don’t forget transitive dependencies and anything an AI coding agent installed on your behalf. - ☐ Remove persistence before you revoke. Locate and stop the
gh-token-monitorservice on any host that ran the install, then rotate GitHub, npm, cloud, Kubernetes, Vault, SSH and browser-saved credentials. In that order. - ☐ Pin and block. Pin to 0.5.143 (or remove the dependency), and run installs with
--ignore-scriptsby default — the pnpm/yarn equivalents exist — allowlisting the few packages that genuinely need lifecycle hooks. A preinstall hook that never runs steals nothing. - ☐ Check what you publish. If any maintainer in your org ran the bad version, look at your own npm packages for versions you didn’t cut. The worm republishes through stolen tokens.
- ☐ Audit the AI-tool configs. Claude, Cursor and Windsurf config files were on the target list. Rotate the API keys stored there and in any MCP server configs on affected machines.
- ☐ Scan continuously. Point PlayCISO’s NPM Scanner → and Package Scanner → at your manifests and the AI Dependency Scanner → at your AI stack, so the next malicious version is caught at install time, not audit time. Keep a live AIBOM → so “are we exposed?” takes minutes.
- ☐ Rehearse the wipe scenario. “A dev laptop has a dead-man’s switch on a stolen token — who touches it first, and in what order?” is a tabletop worth running in the Cyber War Room → before it’s a real Tuesday.
The takeaway
tensorlake@0.5.144 is the same worm with a sharper edge: it skips CI to land on the humans, it carries a valid provenance stamp, and it has made your incident playbook’s first step into a trap. Default-deny install scripts, pin what you consume, fence what you publish, and update the runbook so remove persistence comes before revoke. We’re tracking the full analysis and will update this post as the details are confirmed.
Scan your dependencies with the NPM Scanner and Package Scanner, and rehearse the response in the Cyber War Room. Earlier in this series: @subql and ChainDrop, keyv and the provenance problem.
Frequently asked questions
Which version of tensorlake is malicious?
Version 0.5.144 of the tensorlake npm package. StepSecurity names 0.5.143 as the safe version to pin to. Check with npm ls tensorlake and search your package-lock.json / pnpm-lock.yaml / yarn.lock for 0.5.144.
How does the tensorlake worm infect a machine?
Through an npm preinstall hook that runs setup.mjs. The script checks whether it is running in CI and skips itself there, so developer laptops are the target. It downloads the Bun runtime and uses it to execute an obfuscated payload (~856 KB) hidden under typescript/lib/. Because the release was published through the repository’s own release workflow, it carries a valid npm provenance attestation and looks legitimate.
What does it steal?
GitHub and npm tokens, cloud provider keys, Kubernetes and Vault secrets, SSH keys, saved browser logins, and configuration files for AI coding tools such as Claude, Cursor and Windsurf. With a stolen npm token it also downloads the victim’s own packages, adds itself, bumps the version and republishes them — the self-propagating Shai-Hulud behaviour.
Why shouldn’t I just revoke the stolen GitHub token?
Because the malware installs a persistent “gh-token-monitor” service that watches the stolen token and runs rm -rf on the home directory if the token stops working. Remove that persistence first (and take a forensic copy if you need one), then revoke and rotate. Removing the npm dependency alone does not remove the implant.
What should a security leader do today?
(1) Inventory: find every machine and repo where tensorlake 0.5.144 was installed, including transitively. (2) Contain in the right order: remove the gh-token-monitor persistence, then revoke and rotate GitHub, npm, cloud, Kubernetes, Vault, SSH and browser-saved credentials from those hosts. (3) Pin to 0.5.143 and block install-time scripts by default. (4) Check your own published packages for unexpected new versions — the worm republishes through stolen npm tokens. (5) Treat affected hosts as compromised and rebuild.