LinuxCommandLibrary

osv-scanner

finds vulnerabilities in dependencies

TLDR

Scan directory

$ osv-scanner -r [directory]
copy
Scan lockfile
$ osv-scanner --lockfile=[package-lock.json]
copy
Scan SBOM
$ osv-scanner --sbom=[sbom.json]
copy
Output as JSON
$ osv-scanner -r [directory] --json
copy
Scan specific ecosystem
$ osv-scanner --lockfile=requirements.txt
copy

SYNOPSIS

osv-scanner [options] [targets]

DESCRIPTION

osv-scanner finds vulnerabilities in dependencies. Uses OSV database.
The tool scans lockfiles and SBOMs. Open source vulnerability detection.

PARAMETERS

-r DIR

Scan directory recursively.
--lockfile FILE
Scan specific lockfile.
--sbom FILE
Scan SBOM file.
--json
JSON output.
--config FILE
Configuration file.
--help
Display help information.

CAVEATS

Requires network access. Database coverage varies. Google maintained.

HISTORY

osv-scanner was created by Google for scanning dependencies against OSV database.

SEE ALSO

npm-audit(1), trivy(1), grype(1)

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community