github OWASP/cve-lite-cli v1.46.0
v1.46.0 - Python scanning graduates from experimental

latest release: v1
42 minutes ago

Upgrade note. Python scanning is no longer experimental: findings from --python now count toward --fail-on and --ratchet. Three changes can affect an existing setup.

  • Scans run with --python can now fail where they passed before. Python findings at or above the --fail-on level exit 1, and a new Python finding above a ratchet baseline fails the run.
  • A multi-folder scan now names the folders it could not read: a lockfile that resolved no packages, or a package.json that declares dependencies but has no lockfile, including one at the root. The run exits 3 unless --allow-empty is set, where it used to exit 0. A folder that --prod-only emptied is still a skip and exits 0, unless another folder went unread.
  • A folder with JavaScript and Python together now writes --sbom and --cdx output instead of refusing.

Added

  • --python scans are no longer experimental. Python findings count toward --fail-on and --ratchet like npm ones, in single-folder, mixed and multi-folder scans, and the note that said they did not affect the exit code is gone. --python is still the switch that turns Python on. --fix and --create-pr still refuse Python; with --offline the Python files are reported as not scanned, since the offline database holds npm advisories only; and --sarif on a folder with both JavaScript and Python is still refused.
  • A folder with JavaScript and Python together gets SBOMs: --sbom and --cdx write one document per requested format holding both ecosystems, with pkg:npm/ and pkg:pypi/ identifiers side by side.
  • CycloneDX output carries the dependency graph: each component, and the project itself, lists what it depends on, from the same relationships the SPDX output uses, for npm, pnpm, Yarn, Bun and Python. When a folder's graph cannot be read, the file has no dependency section rather than one saying nothing depends on anything.
  • When a scan finds no lockfile or requirements file at all, it says if one sits below --search-depth and names the depth to rerun with, in the terminal and in the --allow-empty JSON notes.

Changed

  • A multi-folder scan names the folders it could not read instead of leaving them out of "Scanned N folders": a subfolder whose lockfile resolved no packages, and a folder whose package.json declares dependencies but has no lockfile, including the root, a folder above a lockfile folder, and a folder inside another such folder. The run exits 3 unless --allow-empty is set, and the JSON lists them under unscannedFolders. Without --allow-empty the JSON also marks the run partial. A package.json that declares no dependencies of its own, such as a root that only lists workspaces, stays quiet.

Fixed

  • Python SBOMs: a pin that every requirements file only inherits from another is linked to the project instead of left without a relationship, quoted "name" and "version" keys in pyproject.toml are read, and the CycloneDX file records advisories accepted by a ratchet baseline.
  • SPDX output no longer gives two packages the same SPDXID when one package's name matches another's disambiguated id, which made the document invalid.
  • A package-lock.json licence written in the old { type, url } object form is read, so the SPDX SBOM and the licence check no longer drop it.
  • For a vulnerable package more than one level deep, the within-range advice names the parent whose range already allows the safe version, instead of naming the vulnerable package itself, in the terminal and the HTML report.
  • Advisories whose own id is a CVE get an EPSS score. Before, only CVE numbers listed among an advisory's aliases were looked up.
  • When the fix plan merges two parent upgrades into one higher version, it re-checks that version before warning it may not fix a finding, and the chain details printed with it come from the version the merged command actually installs.
  • A transitive finding whose advisory names no fixed version no longer gets a within-range update or parent upgrade to a newer release that is still affected. It says no known safe version exists instead.
  • The update notice treats pre-releases correctly: a stable release counts as newer than its release candidate, and a pre-release is not offered to stable users. An unreadable last-checked time no longer stops update checks for good.
  • overrides --fix keeps package.json's indentation and line endings, such as tabs and CRLF, instead of rewriting the whole file in a different style.
  • In a Yarn Classic workspace, a dependency that resolves to a local workspace package, which Yarn links and leaves out of yarn.lock, is no longer treated as a registry package, so fix commands no longer replace the local link with a registry install.
  • In a pnpm workspace, the fix command for a dependency the workspace root declares carries -w, so pnpm runs it instead of refusing.
  • OA009 only suggests removing an override when every parent's whole declared range, upper bound and pre-release rules included, fits inside the override, and no longer offers removal when a parent's range admits no version at all.
  • When a source file is too large for the phantom-dependency import scan, PD001 and PD002 say they were checked but incomplete and name the skipped file, in JSON, SARIF, the terminal and HTML, instead of being listed among rules that did not run.
  • A pinned requirements.txt line that carries pip options such as --no-binary, --only-binary or --config-settings is read instead of being skipped as unpinned and marking the scan partial.
  • Multi-folder --json output lists the folders --prod-only left with no packages, matching the terminal.
  • --output help, docs and errors say which file extensions make it a file path rather than a folder.

Docs

  • The docs website loads faster on phones: fonts are bundled with the site instead of fetched from Google Fonts, so visitors no longer contact Google, and homepage images are smaller.
  • The CLI reference says a package with a malicious-code (MAL-) advisory fails --fail-on at every level.

Validation

  • npm test
  • npm run build

Contributors

Thank you to everyone whose work is in this release: @2648782102, @aseel-707, @CodeWith-sakib, @Darshan3690, @GandotraDiya, @immHarshitt, @mateuscmtropical, @Medhansh-741, @Mugunth007, @muntasir-396, @Nachiket-Roy, @nios-x, @noor-ulhassan, @prx-my, @sarankumar1325, @Skeletor-Pirate, @WadekarPrashant and @YK-03. Thanks also to @vianmangal for reporting issues fixed here.

Don't miss a new cve-lite-cli release

NewReleases is sending notifications on new releases.