Skip to content

feat(cve): a CVEs tab showing what to bump and what a release would clear - #20

Merged
rjd15372 merged 14 commits into
mainfrom
feat/cve-tab
Nov 17, 2026
Merged

rjd15372 merged 14 commits into
mainfrom
feat/cve-tab

Conversation

@rjd15372

Copy link
Copy Markdown
Collaborator

Summary

A dedicated CVEs tab, public, after Artifacts. The "CVE exposure by project" table moves there from Overview.

  • Staging (default): one row per package to bump, split into "Ours to bump" (packages built in OBS, Go runtime, bundled libraries), "Base OS" and "Not classified yet". Rows expand to the CVEs and the images affected. Entries not yet seen in this browser are tagged NEW and sorted first; "Mark all as seen" clears them. The tab shows an "N new" badge from any other tab.
  • Released: one row per released image with "X of Y fixed in staging" and the current staging version; each CVE is "Fixed in staging", "Still open in staging" (linking to the staging row) or "No staging image to compare".
  • By image: the existing table, unchanged.

How it works

  • The scanner runs trivy with --list-all-pkgs and stores, per finding, the trivy class and type, file path, RPM source package and vendor, and the owning package when exactly one team-built RPM matches. No schema change: the fields live in findings_json.
  • New pure package internal/cvereport classifies findings and builds the report. Vendor starting with Percona or obs:// is ours; Red Hat, Inc. / Fedora Project is base OS; anything else is left unclassified rather than guessed.
  • GET /api/cve/report serves the report from a 30 s cache. The Overview cache became a small generic ttlCache shared by both.
  • "Seen" state is kept in localStorage only.

Upgrade notes

  • On startup, every image whose stored findings predate this change is rescanned once through the normal scan queue. Until then its findings appear under "Not classified yet".
  • Entries marked as seen before that rescan finishes may show as new once more afterwards.

Testing

  • go vet ./... && go test ./... in backend/: pass.
  • npm test in frontend/: 291 tests pass; npm run build: ok.
  • Looked at in a local preview of the built frontend with sample data: all three views in the dark theme, Staging in the light theme, row expansion, "Mark all as seen".
  • Not verified: the phone-width layout by eye, and a real trivy scan end to end through the app (the parser is tested against a fixture modelled on live trivy output).

Design: docs/superpowers/specs/2026-11-17-cve-tab-design.md. Plan: docs/superpowers/plans/2026-11-17-cve-tab.md.

Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
…ries badge

Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
@rjd15372
rjd15372 merged commit e84e06d into main Nov 17, 2026
5 checks passed
@rjd15372
rjd15372 deleted the feat/cve-tab branch November 17, 2026 11:50
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