Skip to main content

dependency-audit:报告依赖漏洞与过时版本

识别项目使用的依赖生态,运行对应漏洞和版本检查工具,并生成按优先级排列的修复建议。审核过程保持配置、锁文件和代码不变。

来源信息

仓库
PramodTKodag/claude-code-skills
最近来源活动
2026年9月29日 11:21
检测到的 SKILL.md 语言
英语
星标
2
分支
0

必要前提

来源覆盖 npm/pnpm/yarn、Go、Python 和 Cargo 项目;每个检测到的生态都需要对应审核工具,工具缺失时列为未运行。

操作说明

提供要检查的项目,或要求核查依赖。流程先识别配置与锁文件,运行原生工具一次,再整理严重性、当前与修复版本、公告 ID 和依赖路径;补丁或小版本建议与需要审查的改动分开列出。

限制

这个 Skill 负责报告和建议,不安装升级或直接修复。工具缺失不能视为通过;公告 ID、严重性和修复版本必须来自实际工具输出。

安装方式

默认使用会先检查来源的 Prompt;你也可以切换为直接命令,或下载本地副本。

检查来源文件

决定是否安装前,请先阅读 SKILL.md,以及 SkillsMP 当前展示的配套文件。

文件资源管理器
2 个文件

正在显示 SKILL.md

SKILL.md
来源说明 · 只读预览
name
dependency-audit
description
Audit a project's dependencies for known vulnerabilities (CVEs) and outdated packages across npm/pnpm/yarn, Go, Python, and Cargo, then produce a prioritized, read-only remediation report. Use when the teammate asks to audit or check dependencies, scan for vulnerable or outdated packages, run a supply-chain / dependency security check, or mentions npm audit, govulncheck, pip-audit, or cargo audit. Read-only — it never edits files or upgrades anything.
user-invocable
true
allowed-tools
["Read","Grep","Glob","Bash(npm audit*)","Bash(npm outdated*)","Bash(pnpm audit*)","Bash(pnpm outdated*)","Bash(yarn audit*)","Bash(yarn outdated*)","Bash(govulncheck*)","Bash(go list*)","Bash(pip-audit*)","Bash(pip list*)","Bash(uv*)","Bash(cargo audit*)","Bash(cargo outdated*)","Bash(jq*)"]
effort
medium
# Dependency audit Scan the dependency graph for **known vulnerabilities** and **outdated packages**, then hand back one prioritized report. **Read-only**: run audit tools, never modify manifests, lockfiles, or code — the teammate (or `/dev-flow`) applies fixes. ## Procedure 1. **Detect ecosystems.** Glob for manifests — `package.json`, `pnpm-lock.yaml`/`yarn.lock`, `go.mod`, `requirements.txt`/`pyproject.toml`, `Cargo.toml`. Report which were found; audit only those. 2. **Run each ecosystem's native tools once** — the exact audit + outdated commands, their `jq` extraction filters, and install hints are in [references/ecosystems.md](references/ecosystems.md). Prefer the tool the lockfile implies (`pnpm` over `npm` when `pnpm-lock.yaml` exists, etc.). 3. **Missing tool = "not run", never a silent pass.** If an audit tool isn't installed, list it under *Tools not run* with the one-line install from the reference; do not infer results from the manifest. 4. **Synthesize** the outputs into the report below. Then stop — propose, don't apply. ## Token discipline (required) - **Never** paste raw `audit`/`outdated` JSON into the conversation. Always pipe it through the `jq` filter in the reference to keep only `{package, severity, id, installed, fixed, path}`, then work from that. - Run each tool **once**; capture the filtered summary and discard the raw output. - Read manifests with `grep`/targeted reads, never whole large lockfiles. - Load `references/ecosystems.md` only when you need a command you don't already have. ## Output Report, most severe first: - **Summary:** `N vulnerabilities (c critical / h high / m moderate / l low), M outdated` across the ecosystems scanned. - **Vulnerabilities** — table: `severity · package · installed → fixed · advisory/CVE · dependency path`. - **Outdated** — table: `package · current → latest · jump (patch / minor / major)`. - **Prioritized remediation:** 1. **Safe now** — patch/minor upgrades that fix a vuln or are low-risk, each with the **exact command**. 2. **Needs review** — major/breaking upgrades, flagged separately with why (API break, transitive pin). - **Tools not run** — any ecosystem whose audit tool was missing, with the install hint. State clearly that nothing was changed. If the teammate wants the fixes applied, recommend running them through `/dev-flow` (or manually) — this skill does not upgrade. ## Guardrails - Read-only: no `Edit`/`Write`, no `npm install`/upgrade, no lockfile changes. - Report severities and versions **as the tools report them** — do not guess CVE IDs or fixed versions. - If a scanned ecosystem has zero findings, say so explicitly rather than omitting it.
在 GitHub 查看