fix(compliance): an empty SBOM claims nothing about the SBOM requirements #412

Merged
sharang merged 1 commits from fix/empty-sbom-not-assessed into main 2026-09-26 10:22:15 +00:00
Owner

Closes #404.

A target whose scan found no components showed the SBOM requirements as Kein Verstoß gefunden, although nothing had been checked:

  • cra-ai-22 Dependency-Monitoring
  • cra-ai-23 Software Bill of Materials
  • cra-ai-33 SBOM-Pflege und Analyse

This is the same principle as #368: claim only what a check actually covered.

Change

  • Agent (evidence/compliance.rs):
    • A requirement whose every binding is a component tool (syft, or the CVE lookup osv) is now Nicht bewertet when the target has no SBOM entries.
    • It carries a new reason, no_components.
    • A failed tool (tool_failed) still takes precedence, being the more specific reason.
  • Unaffected:
    • Requirements checked in the code, for example cra-ai-20.
    • The OSCAL export, which reports violations only.
    • The nightly baselines, which don't pin CRA status.
  • Dashboard: the new reason reads "Die letzte Prüfung hat keine Komponenten erkannt, also wurde nichts geprüft. Die Stückliste entsteht aus einem Lockfile, den Firmware-Quellen oder einem SPS-Projektarchiv."

Checks

  • fmt, and clippy with the CI flags on the agent and both dashboard feature sets.
  • Tests: agent evidence 13 (a new test covers an empty SBOM against one with components), dashboard 41 (the reason text), and the Mongo integration test evidence.

🤖 Generated with Claude Code

https://claude.ai/code/session_01EYKjxacrr6K88DruUmP48p

Closes #404. A target whose scan found no components showed the SBOM requirements as *Kein Verstoß gefunden*, although nothing had been checked: - cra-ai-22 Dependency-Monitoring - cra-ai-23 Software Bill of Materials - cra-ai-33 SBOM-Pflege und Analyse This is the same principle as #368: claim only what a check actually covered. ## Change - **Agent (`evidence/compliance.rs`):** - A requirement whose every binding is a component tool (syft, or the CVE lookup osv) is now **Nicht bewertet** when the target has no SBOM entries. - It carries a new reason, `no_components`. - A failed tool (`tool_failed`) still takes precedence, being the more specific reason. - **Unaffected:** - Requirements checked in the code, for example cra-ai-20. - The OSCAL export, which reports violations only. - The nightly baselines, which don't pin CRA status. - **Dashboard:** the new reason reads *"Die letzte Prüfung hat keine Komponenten erkannt, also wurde nichts geprüft. Die Stückliste entsteht aus einem Lockfile, den Firmware-Quellen oder einem SPS-Projektarchiv."* ## Checks - fmt, and clippy with the CI flags on the agent and both dashboard feature sets. - Tests: agent evidence 13 (a new test covers an empty SBOM against one with components), dashboard 41 (the reason text), and the Mongo integration test `evidence`. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01EYKjxacrr6K88DruUmP48p
sharang added 1 commit 2026-09-26 09:57:32 +00:00
fix(compliance): an empty SBOM claims nothing about the SBOM requirements
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 7m58s
e62c71972d
A target whose scan found no components showed cra-ai-22, 23 and 33
("Software Bill of Materials", "SBOM-Pflege", "Dependency-Monitoring") as
"Kein Verstoß gefunden", although nothing was checked. Requirements checked
on components only (syft and the CVE lookup) are now "Nicht bewertet" with
the reason "no components found" when the SBOM is empty; a failed tool still
takes precedence. Requirements checked in the code are unaffected, and the
OSCAL export (which reports violations only) is unchanged.

Closes #404.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EYKjxacrr6K88DruUmP48p
sharang merged commit 17633083e0 into main 2026-09-26 10:22:15 +00:00
Sign in to join this conversation.