depguard_exposure
Check if a machine was hit by an npm supply-chain attack. Scans lock files, global packages, and cache for known malicious versions and reports remediation steps.
Instructions
Answer "was this machine hit?" after an npm supply-chain incident (worm, hijacked maintainer, malicious release). Scans every lock file under the given paths (npm, pnpm, yarn classic/berry, bun; nested copies included), globally installed packages, and the npm download cache, and matches each exact installed version against ~35k known-malicious npm packages. Reports where each malicious version was found, whether it is installed on disk, whether it runs install scripts, when its tarball was downloaded, and the remediation steps (credential rotation, cleanup). Use this when the user asks whether they are affected by an attack, or as a periodic check. Only exact version matches are reported; clean versions of previously compromised packages are never flagged.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| paths | No | Directories to search for lock files (absolute paths). Default: the user's home directory. | |
| maxDepth | No | Directory depth to search below each path (default: 8) | |
| includeCache | No | Scan the npm download cache (default: true) | |
| includeGlobal | No | Scan globally installed npm packages (default: true) |