OSV Malicious Advisory
scanned 2h ago · by OpenSSF/OSVOpenSSF/OSV advisory MAL-2026-10587 confirms this npm version as malicious. The package's package.json declares scripts.postinstall = "node.init.js", causing.init.js to run automatically on npm install. The script harvests a hardcoded list of roughly 60 credential-shaped environment variables (including NPM_TOKEN, GITHUB_TOKEN, AWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY, STRIPE_*, DB_PASSWORD, and other cloud/provider tokens), reads files under the installer's home directory (~/.npmrc,...
Advisory
MAL-2026-10587
Source
OpenSSF Malicious Packages via OSV
Summary
Malicious code in dayjscore (npm)
Details
The package's package.json declares scripts.postinstall = "node.init.js", causing.init.js to run automatically on npm install. The script harvests a hardcoded list of roughly 60 credential-shaped environment variables (including NPM_TOKEN, GITHUB_TOKEN, AWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY, STRIPE_*, DB_PASSWORD, and other cloud/provider tokens), reads files under the installer's home directory (~/.npmrc, ~/.env*, ~/config.json, ~/credentials.json), and enumerates ~/.config/* for filenames containing token/cred/secret. It additionally collects host identifiers (os.hostname(), os.platform(), process.cwd(), process.pid, timestamp) and POSTs the resulting JSON via https.request to a hardcoded webhook.cool endpoint (tender-deer-80). The package name mimics the popular dayjs library.
Decision reason
One or more suspicious static signals were detected.
References
Decision evidence
public snapshotBehavioral surface
Trivial
Source & flagged code
1 flagged · loading sourcepackage.jsonView file
•scripts.postinstall = node .init.js
High
Install Time Lifecycle Scripts
Package defines install-time lifecycle scripts.
package.jsonView on unpkgFindings
1 High1 Low
HighInstall Time Lifecycle Scriptspackage.json
LowScripts Present