talira

pip-audit

Audit Python environments and dependency files for known vulnerabilities

open sourceApache-2.0free

pip-audit scans Python environments, requirements files and lock files (pyproject.toml and pylock.*.toml) for packages with known vulnerabilities, using the Python Packaging Advisory Database through PyPI's JSON API, or OSV. It can fix vulnerable dependencies itself with --fix, writes columnar, Markdown or JSON output and CycloneDX SBOMs, reuses pip's local cache, and runs from an official GitHub Action or as a pre-commit hook. Trail of Bits created it with support from Google, and it's maintained under the Python Packaging Authority. For many languages at once, see OSV-Scanner.

Problems it solves

  • check my Python dependencies for known security vulnerabilities
  • fail CI when a requirements file has a vulnerable package
  • upgrade vulnerable Python packages automatically
  • generate a CycloneDX SBOM for a Python project

Features

  • audits environments, requirements files and pyproject or pylock lock files
  • PyPI and OSV vulnerability services
  • automatic fixes with --fix
  • CycloneDX SBOM output in XML or JSON
  • columnar, Markdown and JSON output
  • official GitHub Action and pre-commit hook

Capabilities

Has a command line toolplan not known

Alternatives

The same job

These do what pip-audit does.

  1. OSV-Scanner Find known vulnerabilities in your project's dependencies, using OSV.dev
  2. govulncheck Find known vulnerabilities that actually affect your Go code
  3. OWASP Dependency-Check Software composition analysis that finds publicly disclosed vulnerabilities in a project's dependencies
  4. Socket Software supply chain security that catches malicious and risky dependencies
  5. cargo-audit Audit Cargo.lock for crates with known security vulnerabilities
  6. bundler-audit Patch-level verification for Bundler

Compare pip-audit with the top 3