Conversation
Validate security-dispositions.toml, extract HIGH/CRITICAL findings from CodeQL SARIF, Zizmor JSON, and Trivy JSON reports, and classify each as covered, expired, over-cap, or uncovered. Exit 10 on failing findings when enforcement is on and 2 when the file or a report is invalid. Signed-off-by: Jim Meyer <jimeyer@nvidia.com>
Refs NVIDIA#3671 Signed-off-by: Jim Meyer <jimeyer@nvidia.com>
CodeQL, Zizmor, and Trivy now pass their HIGH/CRITICAL findings to the disposition evaluator instead of failing on any count. The evaluator and table are staged from the workflow revision before the candidate checkout, so a scanned candidate cannot approve its own findings. Refs NVIDIA#3671 Signed-off-by: Jim Meyer <jimeyer@nvidia.com>
Refs NVIDIA#3671 Signed-off-by: Jim Meyer <jimeyer@nvidia.com>
|
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
|
The overall direction makes sense, but I think these two points need addressing before this becomes a release gate:
|
Summary
Draft for discussion. The release Security Scan fails on any HIGH/CRITICAL CodeQL, Trivy, or Zizmor finding. This PR lets those findings pass only when a reviewed, expiring entry in
security-dispositions.tomlcovers them. The table and its evaluator come from the workflow revision, not from the scanned tag.Related Issue
Closes #3671 (part of #3559)
Changes
tasks/scripts/security_dispositions.py: a stdlib-only evaluator. It extracts findings from CodeQL SARIF, Zizmor JSON, and Trivy JSON, then matches them on scanner + rule + path. Deferrals expire;rejectedentries don't. Exit codes: 0 = covered or not enforcing, 10 = failing findings, 2 = invalid input. It writes a step summary listing matched, failing, stale, and soon-to-expire entries.security-dispositions.toml: 10 entries for the v0.1.0-pre.11 backlog (8 deferred, 2 rejected). The deferrals carry ansla_exceptionthat cites ci(security): stage release finding enforcement #3552 and feat(ci): record time-limited security finding dispositions for the release gate #3671. The file is added to CODEOWNERS.codeql.yml,trivy-scan.yml,workflow-security.yml: each scanner job first does a sparse checkout of the workflow revision. It copies the evaluator and the table to$RUNNER_TEMP, then deletes the checkout, all before the candidate checkout. The enforce steps now call the evaluator instead of failing on the finding count.trivy-scan.sh reports: prints the report set the table gate reads (consolidated config plus the image and packaged-chart reports), so both gates evaluate the same data.CI.md: SLA windows (7/14/30/90 days), the severity mapping, and how to add, extend, or remove entries.architecture/build.md: one paragraph on the gate.Open questions for review
CI.md, notSECURITY.md.SECURITY.mdis the standard vulnerability-reporting text, so I left it alone.zizmor/template-injectionatrelease-canary.yml:405) is deliberately left uncovered. It should be fixed rather than deferred, so the gate still fails on it.Testing
mise run test:security-dispositions, now part ofmise run test)tasks/scripts/trivy-scan-test.shpasses, including a new check thatreportslists the same filesgatereadsv0.1.0-pre.11):--min-severity=high) are clean on the three edited workflowsmise run pre-commitpasses: every check passes exceptrust:lockfiles:check, which can't run sccache in my local sandbox. This PR changes no Cargo files.v0.1.0-pre.11. The dispatch needs this branch on NVIDIA/OpenShell.Checklist
🤖 Generated with Claude Code