VDB
KO

MAL-2026-11879

Malicious code in @servicetitan/install (npm)

Details

npm/@servicetitan/install is affected by the large-scale, self-propagating npm supply-chain worm of 2026-08-04 (the "Shai-Hulud: Here We Go Again" wave) — the same campaign that began with the compromise of the keyv and cacheable maintainer account. The listed version(s) were trojanized and republished by the worm after it reached an npm publish token belonging to a maintainer in this namespace; the payload enumerates every package a stolen token controls and republishes each with the same hook, so many packages under this scope were poisoned in the same short window. Every poisoned release adds a preinstall hook (`"preinstall": "node setup.mjs"`) that runs on a bare `npm install`, before any project code. setup.mjs downloads a standalone Bun runtime and runs a byte-identical, heavily obfuscated ~728 KB second-stage credential stealer (shipped as Math_Symbol.js / math_init.js). It harvests GitHub, npm, AWS, GCP, Azure, HashiCorp Vault and Kubernetes credentials plus generic secrets and private keys (TruffleHog-style sweep), reads CI/CD secrets and identifies build runners, then republishes further packages the stolen token can reach. Rather than a fixed command-and-control host, it exfiltrates stolen findings to attacker-created GitHub repositories (descriptions reading "Shai-Hulud: Here We Go Again") and over DNS. Treat any environment that installed an affected version (with install scripts enabled) as compromised: rotate and revoke all reachable credentials (npm and GitHub tokens, cloud keys, Vault/Kubernetes secrets, and CI org/repo secrets). Part of the August 2026 npm worm that poisoned 400+ packages across many organizations.

--- _-= Per source details. Do not edit below this line.=-_

## Source: amazon-inspector (7a66eba08245b8768f539b166b415141cc102c98522b472287f0716f9884b6fd) The package's `preinstall` script runs `setup.mjs`, which downloads the Bun runtime from `https://github.com/oven-sh/bun/releases/download/bun-v<version>/<platform>.zip`, extracts it, and then invokes `execFileSync(bunPath, [path.join(__dirname, 'math_init.js')])` to execute a sibling 728 KB Bun-compiled bundle (`math_init.js`) at install time. Both the loader (`setup.mjs`) and the payload (`math_init.js`) are heavily obfuscated: `setup.mjs` uses obfuscator.io-style `_0x...` identifiers and string-lookup object indirection; `math_init.js` begins with `// @bun @bun-cjs` and uses a shuffled string array with hex-named identifiers, rendering the executed code non-auditable. The package's declared purpose is a thin wrapper around `npm install` for private-registry authentication (the `src/` tree implements only cloning `frontend-dev-config`, reading `.npm.json`, and shelling out to `npm install`) and does not require an alternate language runtime or any bundled binary payload. `setup.mjs` and `math_init.js` are not referenced anywhere in the documented source tree and appear inserted alongside the legitimate build output, consistent with a compromised-publish scenario. Fetching an alternate runtime from a non-package-owned release location to execute an opaque, obfuscated bundle at install time is an alternate-runtime dropper pattern.

## Source: ghsa-malware (c923198827f36d1922ceb4ead83e1bdcc8386981386206f4fe9118bb3819a048) Any computer that has this package installed or running should be considered fully compromised. All secrets and keys stored on that computer should be rotated immediately from a different computer. The package should be removed, but as full control of the computer may have been given to an outside entity, there is no guarantee that removing the package will remove all malicious software resulting from installing it.

Are you affected?

Enter the version of the package you're using.

Affected packages

npm / @servicetitan/install

No fixed version published yet for @servicetitan/install (npm). Pin to a known-safe version or switch to an alternative.

References