Repository navigation
ROCm security: scanning workflows, Dependabot and SECURITY.md - #95
Merged
Merged
Conversation
Adds the ROCm GitHub org security baseline, copied verbatim from ROCm/rocm-repo-template (80b94559e): pr-security-scan.yml and weekly-security-scan.yml call the pinned ROCm/rocm-security-gh security-baseline.yml (v1.0.6) for CodeQL, Bandit, Gitleaks, Trivy and zizmor, with their configs under .github/scan_tools_configs. Also adds Dependabot version updates for GitHub Actions and the AMD SECURITY.md. Org policy, never goes upstream, so it stays a separate commit across syncs. Upstream has none of these paths, so it should never conflict.
|
Caution 3 potential secret finding(s) were committed in this pull request. Treat each credential as compromised and revoke or rotate it now, even if a later commit removed it. Deleting the line or force-pushing does not undo the leak: the commits stay reachable from this pull request and from every clone or fork, and automated scanners harvest secrets pushed to public repositories within minutes. If a finding is a test fixture or a false positive, allowlist it in the configuration of the scanner that reported it. Security scan found 3 critical or high finding(s) on lines changed by this pull request (coverage incomplete)
Coverage was incomplete:
View the security scan run for complete reports. “New” means the finding is located in a changed file on an added or modified line; it is not a base-versus-head findings delta. |
Clears every finding the security baseline reports on ROCm-owned code (zizmor 1.30.0 and
trivy 0.70.0, checked locally before and after):
- template-injection: workflow inputs, step outputs and github.token reach run: scripts
through env: instead of ${{ }} (run_tests_against_package.yml ROCm branch,
build_rocm_image.yml).
- unpinned-uses: actions/checkout pinned to the v5.1.0 SHA upstream already uses, in
build_rocm_image.yml and the weekly TE wheel build.
- artipacked: the TE wheel build no longer persists checkout credentials; it only uses
GITHUB_TOKEN through env.
- trivy DS-0026: HEALTHCHECK NONE, the image runs no long-lived service.
- trivy DS-0002: the image stays root like its ROCm base image; USER root is explicit and
the finding is suppressed inline, so upstream Dockerfiles keep reporting it.
Findings in upstream-owned code are left for upstream.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds the ROCm GitHub org security baseline to this fork, as requested by the ROCm Security Baseline rollout. The org-wide "chore: add security scanning workflows" PR was opened on ROCm/jax, rocm-jax, TransformerEngine and jaxpp but never on this repo, so this adds the same files directly.
All files are copied verbatim from ROCm/rocm-repo-template at
80b94559e:.github/workflows/pr-security-scan.yml: scans each PR (changed files only) and reports to the job summary..github/workflows/weekly-security-scan.yml: full scan every Saturday at 10:00 UTC, uploads SARIF to the Security tab.ROCm/rocm-security-ghsecurity-baseline.yml(v1.0.6): CodeQL, Bandit, Gitleaks, Trivy and zizmor, configured under.github/scan_tools_configs/..github/dependabot.yml: daily, grouped version updates for GitHub Actions.SECURITY.md: the only foundational file this repo was missing.README.md,LICENSE,CONTRIBUTING.md,.gitignoreand.github/CODEOWNERSalready exist and are left identical to upstream, so they don't conflict on sync.This is downstream-only and never goes upstream. Upstream has none of these paths, so it won't conflict when
rocm-mainis synced. It becomes a fourth ROCm commit replayed on each sync.Please merge with "Rebase and merge" (or "Squash and merge"), not a merge commit, so
rocm-mainstays linear.Notes for reviewers:
src/maxtext/inference/mlperf/requirements.txtand the TPU post-train requirements), which no ROCm job installs. The 6 secret-scanning alerts are AMD codename keyword matches inside upstream tokenizer vocab files and the C4 test dataset, so they are false positives.Second commit (
a6a2d47da) fixes every finding in ROCm-owned code. zizmor 1.30.0 and Trivy 0.70.0 (the versions the baseline uses) went from 24 findings to 0 and from 2 to 0:github.tokenreachrun:scripts throughenv:instead of${{ }}, in the ROCm branch ofrun_tests_against_package.ymland inbuild_rocm_image.yml.actions/checkoutis pinned to the v5.1.0 SHA upstream already uses. The TE wheel build no longer persists checkout credentials.HEALTHCHECK NONEand an explicitUSER root, with an inlinetrivy:ignore:DS-0002stating why it stays root. Upstream Dockerfiles still report the finding.The remaining Bandit, Trivy and Gitleaks failures are all in upstream-owned code and are left for upstream. Bandit and Trivy scan the whole tree on every PR. Gitleaks attributes three upstream files to this PR's commit only because of the shallow checkout.
Tests
zizmor and Trivy run locally, before and after the fix commit, with the baseline's scanner versions.
pre-commit run --files <the 8 files>: codespell, yamllint and actionlint pass.All workflow YAML and the gitleaks TOML parse.
The PR scan itself runs on this PR.
Checklist
Before submitting this PR, please make sure (put X in square brackets):
gemini-reviewlabel.