chai-as-thread@7.0.8
Malicious code in chai-as-thread (npm)
Analysis
chai-as-thread@7.0.8 is a trojanized clone of the pino logger package, published under a combosquat name. When the exported Express middleware is invoked, index.js spawns a detached background Node.js process (lib/initializeCaller.js) that decodes a hardcoded base64 URL (hxxps://tomato-brunhilda-40[.]tiiny[.]site/index[.]json), fetches its contents via axios, and passes the response body to new Function.constructor("require", response) — executing arbitrary remote code from the attacker-controlled server. The payload retries up to 5 times on failure.
- analyzed by
- Leitwacht
- first seen
- Jul 7, 2026, 06:22 PM
- analyzed
- Jul 7, 2026, 06:32 PM
Related advisories
- chai-as-disarmed@3.2.3
- zredis-typed@1.0.127
- zod-pino434@1.0.127
- polygon-gamma-apis@1.5.2
- execfences@5.0.2
- compose-logger-stand@1.0.126
- assertcoreutils@2.3.2
- pino-zod@1.0.121
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.