Skip to content

feat(vex): import vendor CSAF VEX feeds and share VEX decisions between federated peers - #446

Merged
M0Rf30 merged 3 commits into
mainfrom
feat/vex-import
Nov 9, 2026
Merged

M0Rf30 merged 3 commits into
mainfrom
feat/vex-import

Conversation

@M0Rf30

@M0Rf30 M0Rf30 commented Nov 9, 2026

Copy link
Copy Markdown
Collaborator

Closes #315.

Vendor CSAF VEX feeds

  • Admin-only /api/v1/vex/feeds (CRUD + POST …/{id}/sync) and Settings > VEX feeds. A feed is a CSAF provider-metadata.json, a ROLIE feed or a single document.
  • Per document: .sha256/.sha512 hash check, detached .asc OpenPGP signature verified against pinned pgp_keys or the provider metadata keys (fingerprint-matched); require_signature on by default.
  • Incremental sync (cursor), worker every 15 min honouring the per-feed interval; re-matching after every sync and hourly.
  • known_not_affected / fixed statements are matched to scanned artifacts by versioned PURL (CPE as fallback: product name + exact version) and only for vulnerabilities the scan reports (id or alias). They never replace an admin decision, a peer decision or another feed's statement.
  • vex_statements now carry source_kind (local|csaf|peer), source_name, source_ref; shown in the VEX list, scan findings table, decision dialog and generated VEX notes.

Federated VEX decisions

  • vex_publish on a federated repo serves its local decisions (OpenVEX) at GET /federation/v1/vex (protocol version unchanged; older peers 404).
  • Per-peer vex_trust: ignore (default), suggest (pending suggestions with provenance), apply (applied only where no other statement exists). Fetched at most hourly after a successful pull; errors land in vex_error and never fail the pull.
  • Suggestions: GET/POST /api/v1/repositories/{name}/vex/suggestions[/{id}/accept|dismiss] and a panel on the Security page. Only an operator accept replaces a local decision.

Schema

027_vex_import.sql (+ validate): vex_feeds, vex_feed_statements, vex_suggestions, source columns, federation_peers.vex_trust, federation_repos.vex_publish, six vex.* audit actions. New tables are in NotJournaled.

Verification

  • Unit tests for internal/csaf, internal/vexsync, internal/federation, internal/api; integration tests for the store, federation endpoint/pull hook and API against Postgres.
  • End-to-end throwaway run: the CSAF fixture synced into a real DB marked the matching npm finding suppressed / not_affected with source csaf/<feed>/<document URL>.
  • Web: typecheck, bun test, i18n check (all locales). Not checked visually: headless Chromium failed to load pages on the dev machine.

Docs: docs/security/vex-feeds.md, federation ops/design, SBOM and findings pages, regenerated docs/reference.

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown

Coverage

Coverage vs main
Go, unit + integration 83.3% ±0.0
Go, unit tests only 70.0% -0.1
Go, integration tests only 53.8% -0.3
Web, lines 90.5% ±0.0
Web, functions 84.7% ±0.0
Go by area
Area Coverage vs main
cmd/docgen 80.3% ±0.0
cmd/genformats 90.8% ±0.0
cmd/oa 0.0% ±0.0
cmd/resetpw 0.0% ±0.0
cmd/server 70.2% +0.2
internal/ai 85.6% ±0.0
internal/api 76.9% -0.1
internal/apkkeys 77.1% ±0.0
internal/artifactpath 100.0% ±0.0
internal/attest 84.0% ±0.0
internal/attestation 79.2% ±0.0
internal/audit 97.6% ±0.0
internal/auth 91.5% ±0.0
internal/backup 72.4% ±0.0
internal/bgtask 96.8% ±0.0
internal/blockreason 100.0% ±0.0
internal/branding 93.5% ±0.0
internal/bundlechecks 100.0% ±0.0
internal/clientsetup 93.6% ±0.0
internal/config 96.4% ±0.0
internal/cron 90.0% ±0.0
internal/crypto 91.0% ±0.0
internal/csaf 85.0% new
internal/curation 99.0% ±0.0
internal/database 75.8% +0.1
internal/declarative 84.1% ±0.0
internal/dtrack 85.3% ±0.0
internal/exploit 93.6% ±0.0
internal/federation 81.5% +0.3
internal/format 81.2% ±0.0
internal/formats 88.0% ±0.0
internal/gpgkeys 87.1% ±0.0
internal/group 89.5% ±0.0
internal/httpcache 100.0% ±0.0
internal/httpcompress 93.3% ±0.0
internal/httpx 85.7% ±0.0
internal/imagesbom 81.9% ±0.0
internal/importmeta 93.3% ±0.0
internal/iocopy 100.0% ±0.0
internal/itempath 98.3% ±0.0
internal/lazyre 100.0% ±0.0
internal/license 98.5% ±0.0
internal/licensemeta 87.5% ±0.0
internal/licensepolicy 92.6% ±0.0
internal/limitio 92.9% ±0.0
internal/mcp 89.1% ±0.0
internal/metrics 96.2% ±0.0
internal/middleware 93.9% ±0.0
internal/netutil 93.4% ±0.0
internal/nixkeys 79.6% ±0.0
internal/oacli 85.0% ±0.0
internal/ocimanifest 100.0% ±0.0
internal/ocipath 100.0% ±0.0
internal/ociref 96.8% ±0.0
internal/osv 89.8% ±0.0
internal/passwd 93.3% ±0.0
internal/pathseg 100.0% ±0.0
internal/pglock 79.0% ±0.0
internal/pkgdeps 88.1% ±0.0
internal/presign 99.2% ±0.0
internal/promote 84.5% ±0.0
internal/proxy 86.7% ±0.0
internal/publicurl 96.8% ±0.0
internal/pypisimple 97.9% ±0.0
internal/quarantine 100.0% ±0.0
internal/quayapi 81.2% ±0.0
internal/quota 92.2% ±0.0
internal/recovery 85.3% -0.3
internal/registry 100.0% ±0.0
internal/replication 78.1% ±0.0
internal/repodispatch 85.1% ±0.0
internal/repotype 97.0% ±0.0
internal/sbom 89.9% +0.6
internal/scanexport 96.4% ±0.0
internal/search 90.7% ±0.0
internal/secrets 91.4% ±0.0
internal/storage 84.8% ±0.0
internal/telemetry 92.2% ±0.0
internal/tiering 83.5% ±0.0
internal/trash 96.7% ±0.0
internal/urlparams 100.0% ±0.0
internal/vexsync 80.0% new
internal/vuln 89.9% ±0.0
internal/webhook 86.1% ±0.0
internal/worker 82.5% +0.1
internal/workq 79.5% ±0.0
pkg/ansible 89.8% ±0.0
pkg/apk 96.0% ±0.0
pkg/cargo 95.6% ±0.0
pkg/compactindex 97.8% ±0.0
pkg/composer 94.5% ±0.0
pkg/conan 99.2% ±0.0
pkg/conda 94.8% ±0.0
pkg/deb 81.0% ±0.0
pkg/delta 71.4% ±0.0
pkg/gemversion 100.0% ±0.0
pkg/gpg 86.5% ±0.0
pkg/helm 97.0% ±0.0
pkg/logger 93.8% ±0.0
pkg/maven 96.7% ±0.0
pkg/nix 99.1% ±0.0
pkg/npm 88.0% ±0.0
pkg/nuget 97.6% ±0.0
pkg/pacman 90.4% ±0.0
pkg/pyversion 100.0% ±0.0
pkg/rpm 92.3% ±0.0
pkg/rpmsign 90.5% ±0.0
pkg/rubymarshal 87.1% ±0.0
pkg/xzlimit 78.0% ±0.0
tests/integration 78.8% ±0.0
web 93.7% ±0.0
Web by area (lines)
Area Coverage vs main
src 74.5% ±0.0
src/api 91.9% +0.2
src/components 88.3% +0.1
src/composables 88.7% ±0.0
src/i18n 98.5% ±0.0
src/lib 99.1% ±0.0
src/pages 91.9% ±0.0
src/pwa 97.6% ±0.0
src/router 98.6% ±0.0
src/stores 99.0% ±0.0
src/telemetry 90.9% ±0.0

Full report (HTML, merged profile) in the CI run artifacts

@M0Rf30
M0Rf30 merged commit c7cb3db into main Nov 9, 2026
25 checks passed
@M0Rf30
M0Rf30 deleted the feat/vex-import branch November 9, 2026 13:45
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.

Vulnerability data: import vendor CSAF VEX and share VEX decisions between federated instances

1 participant