agentleFS
arjunprabhulalarjunprabhulal/agent-skills/skills/security/dependency-audit/SKILL.md

dependency-audit

Skill4 starsChanged 4 months agoMITView on GitHub

Assesses what a project depends on — known vulnerabilities, licence obligations, abandoned packages, and supply chain risk. Use this whenever the user asks what their dependencies look like, mentions a CVE or security advisory, needs a licence review, is evaluating whether to adopt a library, or has a dependency tree nobody has looked at in years. For performing the upgrades this identifies, use dependency-upgrade.

32 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use api-audit, container-audit and 7 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • briiirussellSkill

    api-audit

    Audit REST, GraphQL, and RPC APIs against the OWASP API Security Top 10 (2023). Use when the user mentions 'API security,' 'API audit,' 'BOLA,' 'broken object level authorization,' 'BFLA,' 'function-level authorization,' 'mass assignment,' 'API rate limiting,' 'GraphQL security,' 'REST security,' 'API authentication,' 'API authorization,' 'excessive data exposure,' or needs to review API endpoints for security weaknesses.

    Also in 3 projects that use this

  • grichaSkill

    container-audit

    Audit local Docker images and running containers for hardening issues before deploy — privileged flags, root users, stale base images, missing resource limits. Use for pre-deploy container review.

    Also in 3 projects that use this

  • vbrevikSkill

    secret-scan

    Scan git repositories for leaked secrets (API keys, passwords, tokens, certificates) using gitleaks. Detects secrets in git history and current code. Produces STIG V-ID-tagged findings that feed into /stig-compliance as pipeline evidence. Use when (1) reviewing code changes for accidental secret commits, (2) auditing git history for previously committed secrets, (3) /stig-compliance review needs secret detection evidence. Works air-gapped.

    Also in 3 projects that use this

  • OpenAISkill

    threat-model

    Use when Codex is already in the threat-modeling phase of a security scan, the user explicitly invokes $threat-model, or the user explicitly asks to create, update, or persist a repository threat model. Do not use as the primary trigger for full PR, commit, branch, patch, or repository scans.

    Also in 4 projects that use this

  • renfei-designSkill

    a11y-audit

    Audit Figma designs for WCAG accessibility issues — color contrast, minimum font size, touch target sizing, and missing text alternatives. Use when asked to check accessibility, audit contrast ratios, find a11y issues, verify WCAG compliance, or review designs for accessibility problems. Scans nodes, analyzes offline, and annotates issues in Figma.

    Also in 3 projects that use this

  • SentrySkill

    write-tests

    Write tests following project conventions. Use when adding new tests or modifying existing ones.

    Also in 3 projects that use this

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 30 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:

    Done when: every licence in the tree is known and acceptable for how you ship.

    line 69
  2. Distinctive:

    Done when: every critical dependency has a maintenance judgement attached.

    line 81
  3. Distinctive:

    Unused dependencies: check for imports, not just presence

    line 98

“Common” is measured: kept by at least 6 in 10 of the 30 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

Dependency audit

Most of the code shipping in a typical application was written by strangers. An audit answers three questions about that code: is it dangerous, is it legal, and is it maintained.

Scanners answer the first well. The second and third need judgement, and they are where the expensive surprises live — a licence discovered at acquisition, a critical library abandoned three years ago.

1. See the whole tree, not the manifest

Your manifest lists what you asked for. The lockfile lists what you got, and it is usually five to twenty times larger.

npm ls --all | wc -l          # or: pip list, go list -m all, cargo tree

Transitive dependencies are where most risk sits, because nobody chose them. Note the depth and the total count — a project with 1,400 packages has a different risk profile from one with 40, whatever the direct list looks like.

Done when: you are working from the resolved tree, not the manifest.

2. Run the scanners, then triage the output

npm audit --json          # pip-audit, govulncheck, cargo audit, osv-scanner

Scanner output is not a finding list; it is a starting list. Triage each:

  • Is the vulnerable code path reachable from your usage? A deserialization CVE in a library you only use for formatting is not exploitable. govulncheck does this analysis properly; most tools do not.
  • Is it a dev dependency? A vulnerability in a build tool is real but has a different threat model than one in the server.
  • Severity is not priority. A critical in an unreachable path ranks below a medium in your request-handling path.

Report reachability explicitly. A list of 200 unreviewed advisories teaches people to ignore the scanner, which is worse than not running it.

Done when: each advisory is triaged for reachability, not just listed.

3. Check licences before they become expensive

Licence problems surface at the worst moments — an acquisition, an enterprise sale, a distribution change, and are costly to fix retroactively.

npx license-checker --summary        # pip-licenses, go-licenses, cargo-license

Look for:

  • Copyleft (GPL, AGPL) in anything you distribute or run as a service. AGPL in a hosted service is the one that surprises people
  • No licence at all: legally the most restrictive outcome, not the least
  • Licence changes in newer versions. Several major projects have relicensed; an upgrade can silently change your obligations
  • Attribution requirements you are not fulfilling

Done when: every licence in the tree is known and acceptable for how you ship.

4. Assess maintenance, which no scanner does

An unmaintained dependency is a vulnerability with a delay. For anything load-bearing:

  • Last release date, and last commit — a stable library may legitimately be quiet, but check
  • Open issue and PR counts, and whether maintainers respond
  • Bus factor: one maintainer is a real risk
  • Is it archived or deprecated? Sometimes announced only in the README
  • Does a successor exist? Often the community has already moved

Done when: every critical dependency has a maintenance judgement attached.

5. Look for supply chain smells

  • Typosquatting: a package name one character off a popular one
  • Recently published packages with few downloads in the tree
  • Install scripts: postinstall hooks that run arbitrary code at install time
  • Sudden maintainer changes on a popular package
  • Unpinned or floating versions, which mean your build is not reproducible and an upstream compromise reaches you automatically

Done when: nothing in the tree runs code at install time that you have not accounted for.

6. Reduce the surface

The best audit outcome is usually removal, not upgrade:

  • Unused dependencies: check for imports, not just presence
  • Single-function packages you could inline in twenty lines
  • Duplicated capability: three date libraries, two HTTP clients
  • Heavy dependencies used for one trivial feature

Done when: you have a removal list alongside the upgrade list.

Report

Rank by exploitable risk, not scanner severity. For each: what it is, whether it is reachable, what it would take to fix, and what happens if you do nothing. Separate licence findings from security findings — they go to different people and have different deadlines.

State what you could not assess. Reachability analysis is not available in every ecosystem, and saying so is better than implying a clean result.

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.