You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(security): a gitleaks list scan keeps its start and end times in sarif #916
priority/p3-lowPriority P3: a small improvementscope/securitySecurity linters (trivy, bandit, gitleaks, kubeconform) and Vaulttype/bugType bug: the code does not do what it must
_merge_outcomes (security/gitleaks.py:189-197) builds a new ScanOutcome(status, findings, reasons) for a list target and drops the per-file started_utc and ended_utc that BaseSecurityScanner.scan sets (security/base.py:323-325). A list-target Gitleaks scan therefore has no startTimeUtc or endTimeUtc in its SARIF invocation (security/sarif.py:157-163, :211), although #708 says every scanner that ran reports its start and end times. A directory target is unaffected, because it goes through base.scan once.
Copilot's re-review of release PR #905 mentioned this in its summary, without a thread. P3: SARIF 2.1.0 makes these fields optional.
Acceptance criteria
The merged outcome takes the earliest started_utc and the latest ended_utc of the per-file outcomes.
A test with no real Gitleaks binary scans a two-file list and asserts that the SARIF invocation for gitleaks has both times, with start no later than end.
uv run devops ci passes.
Update 2026-10-08: refinement
The fix shipped (v0.2.25): merge_outcomes keeps the earliest start and latest end (security/base.py:115-130). No test pins it.
A two-file list scan with no real Gitleaks asserts the SARIF times, start no later than end.
priority/p3-lowPriority P3: a small improvementscope/securitySecurity linters (trivy, bandit, gitleaks, kubeconform) and Vaulttype/bugType bug: the code does not do what it must
Activity