From d75dd85e2e63c4ea319144a8e766bf9b06dba829 Mon Sep 17 00:00:00 2001 From: Sharang Parnerkar <30073382+mighty840@users.noreply.github.com> Date: Sat, 28 Nov 2026 12:30:29 +0100 Subject: [PATCH] fix(scan): a target known only by its Siemens controllers is matched A PLC target without a project file took the no-code path and never persisted its device entries, so its controllers raised no CVE alerts. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01Q9inRcu428A2iNjDHPEAT9 --- compliance-agent/src/pipeline/orchestrator.rs | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/compliance-agent/src/pipeline/orchestrator.rs b/compliance-agent/src/pipeline/orchestrator.rs index 6c4e8ab..0addf3a 100644 --- a/compliance-agent/src/pipeline/orchestrator.rs +++ b/compliance-agent/src/pipeline/orchestrator.rs @@ -1925,6 +1925,19 @@ impl PipelineOrchestrator { .await?; } None => { + // A control application known only by the Siemens controllers + // it runs on (SPS item 4a): they are its SBOM, matched against + // Siemens' advisories as with a project. + if !target.devices.is_empty() { + let devices = + crate::pipeline::sbom::devices::entries(&target.devices, &target_id); + if let Err(e) = self + .persist_control_app_sbom(target, &target_id, scan_run_id, devices) + .await + { + tracing::warn!(target_id = %target_id, error = %e, "device SBOM persist failed"); + } + } // No code to scan. DAST is attempted for a target the matrix // plans it for, and for a migrated DAST target, which carries no // artifacts at all and relies on its DastTarget row. Anywhere