2fa-secretkey
Fast, minimal two-factor auth helper for Node.js — HMAC-based OTP with zero dependencies
This report shows the evidence for 2fa-secretkey@1.0.4. 7 of 7 known versions are blocked or flagged. The newest version, 1.0.7, is blocked. See all versions.
AI Security Review
scanned 2mo ago · by lpm-firewall-aiThe manifest contains a concrete install-time remote code execution chain: download, write, and detached execution. This is unrelated to the declared TOTP utility and warrants blocking.
Decision evidence
public snapshot- The postinstall hook fetches a JavaScript payload from a hard-coded remote server.
- It writes the downloaded content to a randomly named temporary JavaScript file and starts it detached.
- The downloaded payload is executed during installation without user action, and errors are suppressed.
- The visible package entry point only exposes TOTP helper wrappers and contains no additional network or process execution.
- The referenced local module ./lib/core is absent from this package archive, so the advertised runtime API is incomplete.
Source & flagged code
3 flagged · loading sourceInstall-time lifecycle script matches a deterministic static-gate block pattern.
package.jsonView on unpkgPackage defines install-time lifecycle scripts.
package.jsonView on unpkgThe postinstall hook fetches a JavaScript payload from a hard-coded remote server.
Findings
Affected versions and remediation
This report applies to 2fa-secretkey@1.0.4.
The versions list below shows the verdict for each recorded version.
- Avoid installing 2fa-secretkey@1.0.4. Remove it from direct dependencies and check your lockfile for transitive copies.
- Choose an independently verified alternative or release. This report does not establish that other versions are safe.
- If this version ran, investigate the affected machine and build environment. Rotate credentials it could access and rebuild from a trusted environment.
Evidence last updated: .
Source advisory published: .
Think this verdict is wrong? Dispute it on GitHub or read how reports are produced.