Skip to content

Fix OSV matching - #7

Merged
ShinigamiKiko merged 2 commits into
mainfrom
fix-osv-matching
Oct 15, 2026
Merged

ShinigamiKiko merged 2 commits into
mainfrom
fix-osv-matching

Conversation

@ShinigamiKiko

Copy link
Copy Markdown
Owner

No description provided.

- Offer only the queried package's fixed versions. One advisory can
  cover several packages with their own releases: for
  illuminate/database 6.20.10, GHSA-3p32-j457-pg5x suggested 6.20.11,
  which is laravel/framework's fix and still vulnerable (6.20.12 is).
- Skip advisories for components without a version. OSV returns every
  advisory a package ever had for a versionless PURL; malware (any
  version) is still reported, and a warning lists such components.
- Report every failed OSV lookup, not only timeouts. The scan printed
  "No vulnerabilities" with exit 0 under --fail-on when OSV was
  unreachable; it now prints an ERROR and exits 1 under --fail-on.
- Tell direct from transitive by the dependency graph. cdxgen marks
  dev dependencies (require-dev, devDependencies) optional, so they
  were shown as transitive.
- Show package names with their group (guzzlehttp/guzzle, not guzzle)
  in the components table, fix plan, dependency paths and license
  list; fix-plan groups no longer merge same-named packages of
  different vendors.
The summary counted scope=required as direct and the rest as
transitive, which is production vs dev, not direct vs transitive: a
Symfony app with 67 requirements reported 191/55. ORIGIN marked a
required package transitive as soon as something else also pulled it
in (twig/twig via twig-bundle), and the dependency paths then starred
that parent for update instead of the package itself.

A component is now direct when a root of the dependency graph depends
on it (new "direct" field), and the summary, ORIGIN and the * marker
all follow it. cdxgen leaves the root out for a composer.json without a
"name", the usual case for applications, so the project's require and
require-dev from composer.json supply it; versions still come from
composer.lock and the added root stays out of the report. Without a
root or a project directory, packages nothing else requires count as
direct. Go modules marked indirect stay transitive.
@ShinigamiKiko
ShinigamiKiko merged commit 81ed16b into main Oct 15, 2026
2 of 4 checks passed
@ShinigamiKiko
ShinigamiKiko deleted the fix-osv-matching branch October 15, 2026 12:06
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-15T12:07:37.838404Z 8b3f5f1 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Oct 15, 2026

Copy link
Copy Markdown

Review in Change Stack →

Note

Currently processing new changes in this PR. This may take a few minutes, please wait...

⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: a20f7697-7ed0-4e8b-8d61-2b132fd03bc6
📥 Commits

Reviewing files that changed from the base of the PR and between 231ee45 and 8b3f5f1.

📒 Files selected for processing: 21
  • README.md
  • internal/cli/failon.go
  • internal/cli/scan.go
  • internal/cli/scan_flags.go
  • internal/cli/scan_test.go
  • internal/onlinescan/osv.go
  • internal/onlinescan/osv_pkg_test.go
  • internal/onlinescan/scan_test.go
  • internal/onlinescan/vulnsymbols_test.go
  • internal/output/fixplan.go
  • internal/output/licenses.go
  • internal/output/table.go
  • internal/output/table_origin_test.go
  • internal/sbomscan/depgraph.go
  • internal/sbomscan/direct.go
  • internal/sbomscan/direct_test.go
  • internal/sbomscan/fixplan.go
  • internal/sbomscan/fixplan_test.go
  • internal/sbomscan/remediate.go
  • internal/sbomscan/report_types.go
  • internal/sbomscan/sbomscan.go
+-------------------------------------------------------------+
| Jurassic Park would have been a lot shorter with me around. |
+-------------------------------------------------------------+
  \
   \   (\__/)
       (•ㅅ•)
       /   づ
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant