dep-vetting
Vet a single package BEFORE adding it as a dependency - reputation, typosquat check, maintainer history, install scripts, blast radius - using postmortem and mlab.sh. Use when the user asks "can I trust this package", considers adding a dependency (npm i / cargo add / pip install X), or compares candidate libraries.
- License 许可
- MIT
- 最近更新
- 2026-10-22
- Stars
- ★ 1
- Forks
- 0
01 前言 Front Matter
- name
- dep-vetting
- description
- Vet a single package BEFORE adding it as a dependency - reputation, typosquat check, maintainer history, install scripts, blast radius - using postmortem and mlab.sh. Use when the user asks "can I trust this package", considers adding a dependency (npm i / cargo add / pip install X), or compares candidate libraries.
03 SKILL.md 正文
Dependency Vetting
CLI details and preflight:
${CLAUDE_PLUGIN_ROOT}/docs/postmortem-reference.md. mlab output shapes:${CLAUDE_PLUGIN_ROOT}/docs/tool-reference.md.
The package is NOT installed yet and must not be during vetting. Everything below inspects it from the outside.
Workflow
1. Preflight
postmortem --version. Identify the exact package name and ecosystem the user means - one typo here and you vet the wrong (or the squatting) package.
2. Typosquat first
Before anything else: is THIS name the package they think it is? Compare against the popular package it resembles (postmortem ships offline typosquat corpora per ecosystem and flags this in scans; for a not-yet-added package, check manually: edit distance to famous names, download counts wildly lower than the lookalike, recent creation date). A hit here ends the vetting - report the squat.
3. History and provenance
- npm:
postmortem timeline <pkg>- maintainer handovers, when install scripts appeared, repository moves. A handover immediately followed by a new install script is the classic takeover shape. - Add the package to a THROWAWAY manifest in a temp dir (manifest + lockfile resolution only, never an install with scripts):
mkdir /tmp/vet && cd /tmp/vet && npm i --package-lock-only <pkg>(or ecosystem equivalent), thenpostmortem scan .,postmortem tree . --online,postmortem scripts .- what does it pull in, who controls that subtree (tree --online --human), does anything run at install? postmortem why <pkg> /tmp/vet --blastfor what a future compromise would reach in the user's real project shape.
4. mlab pivots
- Package homepage/repository domains →
scan_url; young or oddly registered domains are a flag. - Known advisories → the throwaway lockfile through
scan_sbom, KEV/EPSS triage. - Any malware family or IOC surfacing → standard pivots (
scan_hash,search_actors).
5. Verdict
## Vetting: <pkg>@<version> (<ecosystem>) - <adopt | adopt with pins | avoid>
| Check | Result |
|---|---|
| Typosquat | |
| Maintainer history | |
| Install scripts | |
| Transitive tree (size, controllers) | |
| Known vulns | |
| Static scan | |
**Recommendation:** <one sentence + conditions: pin exact version, disable scripts, watch with postmortem watch>
Rules
--package-lock-onlyresolution (no scripts executed) is the hard boundary; if an ecosystem cannot resolve without executing, inspect the registry metadata instead and say the check was shallower.- "Popular" is not "safe" and "small" is not "risky"; the verdict argues from evidence, not stars.
- Vet the exact version being adopted; a clean 4.2.1 says nothing about 4.3.0-beta.
04 同仓库更多 Skills
threat-watch
Generate a threat landscape digest from mlab.sh - recent critical/KEV CVEs filtered to a declared technology stack, with actor attribution. Use when the user asks what is new in vulnerabilities, wants a daily/weekly threat brief, asks about recent CVEs for a product, or sets up a recurring watch on their stack.
supply-chain-audit
Full supply-chain audit of a project - postmortem detects malicious code, install hooks and risky dependencies locally, then mlab.sh enriches what it finds (hashes, endpoints, actors, CVEs). Use when the user asks to audit a project's dependencies or supply chain, check a repo for malicious packages, or vet a codebase before adoption or deployment.
smishing-campaign
Analyze a batch of reported SMS/text messages through mlab.sh - score each for smishing, cluster them into campaigns, and extract the shared infrastructure (URLs, callback numbers, sender patterns). Use when the user has multiple reported SMS from users/employees, or investigates an SMS phishing wave. For a single message, phishing-triage does the job.
script-triage
Statically analyze a suspicious shell script through mlab.sh - install.sh, cron payloads, CI steps, curl-pipe-sh one-liners. Flags dangerous constructs (download-piped-to-shell, base64 decoding, reverse shells, persistence, anti-forensics, destructive deletes), extracts every IOC and enriches them. Use when the user pastes shell code and asks if it is safe/malicious, or provides a .sh file to vet before running it.
sbom-export
Generate a CycloneDX SBOM locally with postmortem and push it through mlab.sh vulnerability scanning - for projects or container images where no single lockfile can be pasted. Use when the user asks for an SBOM, needs vuln scanning of a container image or a multi-ecosystem repo, or when sbom-audit lacks a usable lockfile.
sbom-audit
Audit a dependency lockfile or SBOM for known vulnerabilities via mlab.sh, prioritize findings by KEV status and EPSS, and attribute actively exploited CVEs to threat actors. Use when the user provides a lockfile (package-lock.json, yarn.lock, pnpm-lock.yaml, Cargo.lock, requirements.txt, poetry.lock, uv.lock, Pipfile.lock, go.sum, composer.lock, Gemfile.lock, pom.xml, gradle.lockfile, packages.lock.json, pubspec.lock, mix.lock) or a CycloneDX / SPDX SBOM, or asks to check dependencies for vulnerabilities.