reading-cookies@6.13.2
Malicious code in reading-cookies (npm)
Analysis
reading-cookies@6.13.2 is a second-stage RCE loader disguised as a pino-logger-like package. Its index.js exports a middleware function that spawns lib/caller.js as a detached background node subprocess (detached:true, stdio:ignore, child.unref()). caller.js contains a base64-obfuscated C2 URL pointing to api[.]jsonstorage[.]net/v1/json/... — it fetches the remote endpoint via axios, extracts .data.cookie from the response, and executes the downloaded content as arbitrary code via new Function.constructor("require", s), passing the real require so the payload can import any module. The package name "reading-cookies" is a decoy; the description is a copy-pasted vulnerability-management text unrelated to the code; the publisher uses a throwaway Outlook address; and the package bundles legitimate pino source files as camouflage while jumping directly to version 6.13.2 to appear established.
- analyzed by
- Leitwacht
- first seen
- Jun 11, 2026, 09:15 AM
- analyzed
- Jun 11, 2026, 09:16 AM
Related advisories
- tailwind-typography-plus@2.1.0
- myria-core-sdk@0.0.248
- mountly@0.2.2
- mountly-tailwind@0.1.3
- postcss-processor-utils@1.0.3
- fastify-addon@5.1.0
- metrica-node@2.4.5
- vite-config-optimizer@1.1.4
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.