Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
wu529778790 avatar

Dependency Audit

  • 402 installs
  • Updated June 24, 2026
  • wu529778790/shenzjd-skills

dependency-audit is an agent skill that scans project dependencies for CVE vulnerabilities, outdated packages, and license compliance across npm, Go, Python, and Rust.

About

dependency-audit is a Claude Code skill that scans a project's dependencies for security vulnerabilities, outdated packages, and license compliance issues. It detects the package manager from lockfiles and runs the matching tool (npm audit, govulncheck, pip-audit, cargo audit) across npm, yarn, pnpm, Go, Python, and Rust ecosystems, then flags CVEs, outdated packages, duplicate versions, and copyleft licenses. It outputs a severity-sorted report with executable fix commands. The skill's docs are written primarily in Chinese.

  • CVE scanning across npm, Go, Python, Rust
  • License compliance (GPL/AGPL detection)
  • Severity-sorted report with fix commands

Dependency Audit by the numbers

  • 402 all-time installs (skills.sh)
  • +60 installs in the week ending Jul 27, 2026 (Skillselion tracking)
  • Ranked #556 of 2,203 Security skills by installs in the Skillselion catalog
  • Data as of Jul 27, 2026 (Skillselion catalog sync)
At a glance

dependency-audit capabilities & compatibility

free, no API key; uses local package-manager audit tools

Capabilities
dependency audit · cve scanning · license compliance · outdated detection
Use cases
security audit
Pricing
Free
From the docs

What dependency-audit says it does

Use when auditing project dependencies for security vulnerabilities, outdated packages, or license compliance across npm/yarn/pnpm, pip, go, and cargo.
SKILL.md
CVE scanning, severity classification
README.md
npx skills add https://github.com/wu529778790/shenzjd-skills --skill dependency-audit

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs402
Last updatedJune 24, 2026
Repositorywu529778790/shenzjd-skills

Do my project's dependencies have known CVEs, outdated versions, or risky copyleft licenses?

security-audit

Who is it for?

Developers checking dependency security and license compliance across multiple package ecosystems.

Skip if: Code-level security review, Docker image scanning, or deep license analysis.

When should I use this skill?

Auditing project dependencies for security vulnerabilities, outdated packages, or license compliance across npm/yarn/pnpm, pip, go, and cargo.

What you get

A severity-sorted audit report of vulnerabilities, outdated packages, and license risks with executable fix commands.

  • Severity-sorted dependency audit report
  • Executable fix commands

By the numbers

  • 6 supported package-manager ecosystems
  • 4 audit dimensions

Files

SKILL.mdMarkdownGitHub ↗

Dependency Audit

扫描项目依赖,检测安全漏洞、过时包和 license 合规问题。

Overview

全面审计项目依赖:CVE 漏洞扫描、过时依赖检测、license 合规检查、重复依赖分析。输出按严重程度排序的安全报告和可执行的修复命令。

When to Use

  • User wants to check dependency security
  • User mentions CVE, vulnerability, or audit
  • User wants to know outdated dependencies
  • User says "审计依赖" / "check dependencies"
  • User inputs /dependency-audit

When NOT to Use:

  • User only wants to update versions
  • User wants code-level security review
  • User wants to analyze runtime dependencies
  • User wants deep license analysis
  • User wants to scan Docker images

Core Pattern

Step 1: 检测包管理器

检测文件包管理器审计命令
package-lock.jsonnpmnpm audit
yarn.lockyarnyarn audit
pnpm-lock.yamlpnpmpnpm audit
go.sumGogovulncheck ./...
requirements.txt / Pipfile.lockPythonpip-audit
Cargo.lockRustcargo audit

Step 2: 漏洞扫描

# 工具可用性检查
check_tool() {
  command -v "$1" >/dev/null 2>&1 || { echo "⚠️ $1 未安装,跳过 $2 审计"; return 1; }
}

# npm
if check_tool "npm" "npm"; then
  npm audit --json 2>/dev/null | python3 -c "
import sys,json
data=json.load(sys.stdin)
vulns=data.get('vulnerabilities',{})
print(f'Total: {len(vulns)} vulnerabilities')
for name,v in vulns.items():
    via=v.get('via',[])
    title=next((x.get('title','') for x in via if isinstance(x,dict) and x.get('title')),'')
    print(f'  {name}: {v.get(\"severity\",\"unknown\")} - {title}')
" || echo "npm audit 失败,尝试: npm audit fix"
fi

# Go
if check_tool "go" "Go"; then
  go install golang.org/x/vuln/cmd/govulncheck@latest 2>/dev/null
  $(go env GOPATH)/bin/govulncheck ./... 2>/dev/null || echo "govulncheck 失败,检查 Go 版本"
fi

# Python
if check_tool "pip-audit" "Python"; then
  pip-audit 2>/dev/null; rc=$?; if [ $rc -gt 1 ]; then echo "pip-audit 执行失败 (exit $rc),尝试: pip install pip-audit"; fi
else
  echo "安装 pip-audit: pip install pip-audit"
fi

Step 3: 过时依赖检测

# npm
if command -v npx >/dev/null 2>&1; then
  npx npm-check-updates --format table 2>/dev/null || echo "npm-check-updates 失败"
else
  echo "⚠️ npx 未安装,跳过 npm 过时检测"
fi

# Go
if command -v go >/dev/null 2>&1; then
  go list -m -u all 2>/dev/null | grep "\[" || echo "无过时依赖"
else
  echo "⚠️ go 未安装,跳过 Go 过时检测"
fi

# Python
if command -v pip >/dev/null 2>&1; then
  pip list --outdated 2>/dev/null || echo "pip list 失败"
else
  echo "⚠️ pip 未安装,跳过 Python 过时检测"
fi

统计:

  • 过时依赖数量
  • major / minor / patch 升级分布
  • 是否有安全相关的更新

Step 4: License 合规检查

# npm
if command -v npx >/dev/null 2>&1; then
  npx license-checker --json 2>/dev/null | python3 -c "
import sys,json
data=json.load(sys.stdin)
licenses={}
for k,v in data.items():
    lic=v.get('licenses','UNKNOWN')
    licenses[lic]=licenses.get(lic,0)+1
for l,c in sorted(licenses.items(),key=lambda x:-x[1]):
    print(f'  {l}: {c}')
" || echo "license-checker 失败"
else
  echo "⚠️ npx 未安装,跳过 npm license 检查"
fi

# Go
if command -v go-licenses >/dev/null 2>&1; then
  go-licenses csv . 2>/dev/null || echo "go-licenses 失败"
else
  echo "⚠️ go-licenses 未安装,跳过 Go license 检查"
  echo "安装: go install github.com/google/go-licenses@latest"
fi

检测:

  • 是否有 GPL/AGPL 等 copyleft 许可证
  • 是否有未知/自定义许可证
  • 许可证兼容性

Step 5: 生成报告

使用 templates/audit-report.md 模板,输出:

1. 安全概览 — 漏洞数量和严重程度分布 2. 高危漏洞 — 需要立即修复的 CVE 3. 过时依赖 — 按升级难度排序 4. License 合规 — 风险许可证列表 5. 修复命令 — 每个问题附带可执行命令

Quick Reference

/dependency-audit                    # 完整审计
/dependency-audit --security         # 只检查安全漏洞
/dependency-audit --licenses         # 只检查 license
/dependency-audit --fix              # 自动修复可安全升级的依赖
参数说明默认值
--security只检查安全漏洞false
--licenses只检查 license 合规false
--fix自动修复false

Common Mistakes

错误正确做法原因
只看 high/criticalmedium 也需要关注很多攻击链从 medium 升级而来
盲目升级所有依赖逐个升级并测试major 升级可能有 breaking changes
不检查 transitive 依赖分析完整依赖树漏洞常出在间接依赖中
忽略 license 合规定期检查 licenseGPL 传染性风险
audit 后不更新 lock 文件重新生成 lock 文件确保修复生效
忽略已弃用的依赖检查弃用警告弃用包可能有安全风险

Related skills

FAQ

Which ecosystems are supported?

npm, yarn, and pnpm via npm audit, Go via govulncheck, Python via pip-audit, and Rust via cargo audit.

What does it check besides CVEs?

Outdated dependencies with upgrade-type breakdown, duplicate versions, and license compliance including GPL/AGPL detection.

Securityauditcompliance

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.