agentleFS
tejastn10tejastn10/workbench/skills/security/audit-dependencies/SKILL.md

audit-dependencies

Skill1 starsChanged 2 months agoMITView on GitHub

Run the dependency audit for a repo's stack, triage the findings by reachability and severity, and update packages safely — lockfile regenerated, changelog noted, tests green. Covers npm audit / npm outdated, govulncheck / gosec / go list -u, pip-audit / poetry show --outdated. Use when asked to "audit dependencies", "update packages", "check for CVEs", "bump the lockfile", or on a schedule.

5 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 3 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 4 edited versions we read keep these.

  • 3

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    no fix → is there a maintained fork, a config mitigation, or a way to drop the dependency?

    line 31
  2. Distinctive:

    Prefer the smallest version jump that clears the advisory over "latest".

    line 39
  3. Distinctive:

    Run the full test suite + typecheck + lint.

    line 40

“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Audit & update dependencies

1. Run the audit

StackVulnerabilitiesOutdated
Nodenpm audit --audit-level=lownpm outdated
Gogovulncheck ./... · gosec ./...go list -m -u all
Pythonpip-audit · safety checkpoetry show --outdated

Match the tool to what the repo's CI already runs (the security-audit.yml workflows use npm audit --audit-level=low, gosec + govulncheck, safety).

2. Triage each finding

For every advisory, in order:

  1. Reachable? govulncheck says so directly. For npm/pip, is the vulnerable package a runtime dependency or dev/build-only, and is the vulnerable function actually called? A critical CVE in an unreachable dev tool is ⚪, not urgent.
  2. Severity + exploitability — CVSS, and whether the exploit needs conditions this service doesn't have (a public endpoint, a specific input path).
  3. Fix path:
    • patch available in a compatible range → bump, lowest version that clears it
    • fix only in a major version → separate PR, check the changelog for breaks
    • no fix → is there a maintained fork, a config mitigation, or a way to drop the dependency? Otherwise document the accepted risk with an expiry date.

3. Update safely

  • One concern per PR: security bumps separate from feature-driven bumps.
  • Bump the manifest and regenerate the lockfile (npm install, poetry lock, go mod tidy) — commit both.
  • Prefer the smallest version jump that clears the advisory over "latest".
  • Run the full test suite + typecheck + lint. For a transitive-only bump with no behaviour change, say so in the PR.
  • Note it: conventional-commit fix(deps): bump <pkg> to <version> (CVE-…) or chore(deps): …; add a CHANGELOG.md line if the repo keeps one.
  • Toolchain bumps (Go / Node major) → confirm CI matrix, Dockerfile base image, and runtime base all move together.

4. Verify

  • Re-run the audit — the advisory is gone, no new ones introduced.
  • CI security-audit job is green.

Anti-patterns

  • ❌ npm audit fix --force blind — it happily makes breaking major bumps.
  • ❌ Bumping to latest when a patch release clears it.
  • ❌ Manifest bumped, lockfile not regenerated.
  • ❌ Mixing a security bump with unrelated dependency churn in one PR.
  • ❌ Closing a "no fix available" advisory with no documented decision.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.