feat(sbom): sbomqs quality score as CRA evidence for the SBOM (#496)
CI / Check (push) Skipped
CI / Detect Changes (pull_request) Skipped
CI / Deploy Agent (pull_request) Skipped
CI / Deploy Dashboard (pull_request) Skipped
CI / Deploy Docs (pull_request) Skipped
CI / Deploy MCP (pull_request) Skipped
CI / Check (pull_request) Successful in 9m45s
CI / Check (push) Skipped
CI / Detect Changes (pull_request) Skipped
CI / Deploy Agent (pull_request) Skipped
CI / Deploy Dashboard (pull_request) Skipped
CI / Deploy Docs (pull_request) Skipped
CI / Deploy MCP (pull_request) Skipped
CI / Check (pull_request) Successful in 9m45s
At the end of every completed scan the target's CycloneDX SBOM (the same document as the evidence pack's sbom.cdx.json) is scored by sbomqs against BSI TR-03183-2 v2.1 and the NTIA minimum elements (2021). - Dockerfile.agent pins sbomqs 2.1.2 (Apache-2.0) with the sha256 from the release's checksums.txt and lists it in tool-versions.json. - Profiles by explicit name (bsi-v2.1, ntia-2021): in 2.1.2 `bsi` and `ntia` float to the newest BSI and CISA 2026 profiles. - pipeline/sbom_quality.rs runs it offline through tool_cmd (empty environment, 120 s), keeps per profile the score, grade and the checks not fully met; stored on the scan run as sbom_quality. Without sbomqs the run records the skipped stage sbom_quality. - Supporting evidence, not findings: attached to cra-ai-23 in the CRA status without changing its state, sbom-quality.json in the evidence pack, GET /api/v1/sbom/quality for the SBOM page. - Dashboard: SBOM-Qualität card on the SBOM page, a supporting-evidence line on cra-ai-23 on the CRA page. - Docs: tools.md, SBOM and target guides, staging check 20. Our export (CycloneDX 1.5, no creator, timestamp, supplier or hashes) grades F against BSI; the failed checks list what it needs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB
This commit is contained in:
1 parent
d406741907
commit
0c1024dd60
21 files changed
+984
-12
No files matched your search
@@ -179,7 +179,8 @@ its name, type and artifacts, and the buttons:
|
||||
- **Prüfung starten** (Run scan) -- starts a scan now.
|
||||
- **Nachweispaket herunterladen** (Download evidence pack) -- a ZIP with the
|
||||
OSCAL assessment (CRA Annex I), the SBOM (CycloneDX, SPDX), the findings
|
||||
(JSON, CSV), the CVE alerts and a manifest with SHA-256 checksums.
|
||||
(JSON, CSV), the CVE alerts, the SBOM's quality score (`sbom-quality.json`,
|
||||
once a scan has scored it) and a manifest with SHA-256 checksums.
|
||||
- **Bearbeiten** (Edit) -- see below.
|
||||
- **Löschen** (Delete) -- see below.
|
||||
|
||||
|
||||
@@ -249,6 +249,29 @@ API: `GET /api/v1/targets/{id}/cves` lists the alerts with their statements,
|
||||
(`{"status": "not_affected", "justification": "…", "impact_statement": "…"}`),
|
||||
`GET /api/v1/targets/{id}/vex?format=openvex|cyclonedx` downloads the document.
|
||||
|
||||
## SBOM quality
|
||||
|
||||
When a target is selected on the **Pakete** tab, **SBOM-Qualität** (SBOM
|
||||
quality) shows how the exported CycloneDX document meets two standards, as
|
||||
[sbomqs](https://github.com/interlynk-io/sbomqs) scores it at the end of each
|
||||
scan:
|
||||
|
||||
- **BSI TR-03183-2 v2.1** -- the German technical guideline for SBOMs under
|
||||
the CRA
|
||||
- **NTIA Minimum Elements (2021)**
|
||||
|
||||
Each line has sbomqs's grade (A to F) and score out of 10. Open it for the
|
||||
checks the SBOM does not fully meet, marked **Pflicht** (required) or
|
||||
**zusätzlich** (additional), with what sbomqs found. The score is supporting
|
||||
evidence for the CRA requirement **cra-ai-23** (SBOM): it is shown there on
|
||||
the target's CRA page and is in the evidence pack as `sbom-quality.json`, but
|
||||
it raises no findings and does not change the requirement's state.
|
||||
|
||||
The score rates the document, not the software. Today's export is CycloneDX
|
||||
1.5 without suppliers, hashes or the TR's component properties, so BSI
|
||||
TR-03183-2, which asks for CycloneDX 1.6 and those fields, grades it low; the
|
||||
failed checks list what the export would need.
|
||||
|
||||
## Compare Tab
|
||||
|
||||
**Vergleich** compares the SBOMs of two targets, for example two firmware
|
||||
|
||||
@@ -135,6 +135,12 @@ vulnerabilities.
|
||||
|
||||
Syft output feeds into both the SBOM feature and the vulnerability scanning pipeline.
|
||||
|
||||
## sbomqs -- SBOM Quality
|
||||
|
||||
[sbomqs](https://github.com/interlynk-io/sbomqs) (Interlynk, Apache-2.0; pinned with its checksum in the agent image) scores the CycloneDX document Prüfwerk exports for a target, the same bytes as the evidence pack's `sbom.cdx.json`, at the end of every completed scan (`pipeline/sbom_quality.rs`). Two profiles, by their explicit names: `bsi-v2.1` (BSI TR-03183-2 v2.1) and `ntia-2021` (NTIA minimum elements). In sbomqs 2.1.2 the short names float (`bsi` is the newest BSI version, `ntia` the CISA 2026 elements), so they are not used.
|
||||
|
||||
The score per profile, its grade and the checks not fully met are stored on the scan run (`sbom_quality`), shown on the SBOM page, attached to the CRA requirement cra-ai-23 as supporting evidence and written to the evidence pack (`sbom-quality.json`). They raise no findings. sbomqs runs offline: its component analysis, which would call Interlynk's API, is opt-in and never turned on, and the tool starts with an empty environment like every other tool. A scan without sbomqs (a development machine) records the skipped stage `sbom_quality`.
|
||||
|
||||
## Embedded Library Versions
|
||||
|
||||
Libraries copied into a firmware tree have no manifest Syft could read.
|
||||
|
||||
@@ -475,6 +475,27 @@ alerts (e.g. the log4j/gson target of check 19).
|
||||
In managed repositories new High findings go through LLM triage and open
|
||||
tracker issues on that first rescan (#451).
|
||||
|
||||
### 24. #496 SBOM quality score (sbomqs)
|
||||
|
||||
- **Do:** after the deploy, `docker exec` into the agent and run
|
||||
`sbomqs version` and `cat /opt/pruefwerk/tool-versions.json`; then scan any
|
||||
target with components (e.g. `fixtures/nightly/js-npm-lock-v3`).
|
||||
- **Expect:** `v2.1.2`, and `"sbomqs":"2.1.2"` in the tool versions. On
|
||||
**SBOM**, with the target selected, **SBOM-Qualität** lists
|
||||
"BSI TR-03183-2 v2.1" and "NTIA Minimum Elements (2021)" with a grade and
|
||||
score each; opening one lists the failed checks (e.g. `sbom_spec_version`,
|
||||
"CycloneDX 1.5 does not meet minimum version 1.6"). The target's CRA page
|
||||
shows the same scores on **cra-ai-23**, whose state is unchanged. The
|
||||
evidence pack has `sbom-quality.json`, listed in `manifest.json`. No new
|
||||
findings.
|
||||
- **Log:** `SBOM quality (sbomqs)` with the scores per profile. No outbound
|
||||
connection from sbomqs.
|
||||
- **Switch:** none; without the binary the run records the skipped stage
|
||||
`sbom_quality` ("sbomqs is not installed").
|
||||
- **[visible]** SBOM-Qualität card on the SBOM page, the score on cra-ai-23,
|
||||
`sbom-quality.json` in the evidence pack. Expect a low BSI grade until the
|
||||
export carries CycloneDX 1.6 and the TR's fields.
|
||||
|
||||
## After the pass
|
||||
|
||||
- The nightly job on `main` is green with the new mobile targets.
|
||||
|
||||
Reference in new issue
Block a user