Skip to the content
AI and Cybersecurity Learning and Practice Center Test automation Open the Learning Center

Best practiceDependencies and supply chain

Curate dependencies: approve, pin, verify, and re-check

OWASP ASI04OWASP LLM03

npm worms, phished maintainers and slopsquatted packages all land through "install the latest". A curated catalog with pinned, scanned versions is the difference between reading about Shai-Hulud and being in it.

What to do

  1. Pin exact versions with lockfiles and install from a registry proxy that serves only approved packages.
  2. Scan every new version against OSV, GHSA and vendor feeds before approval; block critical and high findings by policy.
  3. Verify provenance where available (npm and PyPI trusted publishing, Sigstore, SLSA) and be wary of a package that suddenly changes maintainers or install scripts.
  4. Never install a package an AI suggested without checking it exists, is maintained and is the one you meant.

Sources

Check your own AI plan against the practices: Plan check