ts-linting-builder@2.1.2
Malicious code in ts-linting-builder (npm)
Analysis
ts-linting-builder@2.1.2 runs a postinstall hook (node test.js) that activates two credential-theft and backdoor payloads on install. Payload 1 (from_str_1) walks the current working directory for files named .env, id.json, config.toml, and Config.toml and uploads them to hxxps://datasecure-service[.]vercel[.]app/api/v1 with the victim's username. Payload 2 (from_str_2) fetches an SSH public key from hxxps://datasecure-service[.]vercel[.]app/api/ssh-key and appends it to ~/.ssh/authorized_keys, then executes sudo ufw enable and sudo ufw allow 22/tcp to open SSH access. It also fetches file-pattern lists from the same C2, recursively scans the home directory (or Windows drives) for matching files, and exfiltrates them via multipart POST to hxxps://datasecure-service[.]vercel[.]app/api. The package declares child_process and os as npm dependencies to shadow Node.js core modules for this purpose.
- analyzed by
- Leitwacht
- first seen
- Jun 29, 2026, 10:54 AM
- analyzed
- Jun 29, 2026, 10:55 AM
Related advisories
- ts-lint-builders-v2.1@2.1.0
- ts-ankle@1.1.0
- block-slot@1.0.9
- node-slot@1.0.7
- data-utils-bcf2@1.0.0
- typescript-util-core@7.1.5
- typescript-util-core@3.5.0
- system-driver@1.0.1
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.