Repository navigation
Update: add Checkmarx One scan workflow for public repo testing - #2
cx-shrinil-modhave wants to merge 3 commits into
Conversation
Original alert (resolved)Security Policy Alert: Secret Policy ViolationThis workflow run has been blocked by StepSecurity's secrets policy because it accesses secrets and the workflow file differs from the default branch. Secret references detected:
To approve this workflow, please add the Note: The label must be added by someone other than the PR author (cx-shrinil-modhave) or automation bots to ensure proper security review. After the label is added, you can re-run the blocked workflow to proceed. This workflow will be automatically approved once merged into the default branch. For more information, see StepSecurity's Secret Exfiltration Policy documentation. |
cx-jonathan-hartman
left a comment
There was a problem hiding this comment.
A couple minor suggestions and otherwise LGTM.
Is this still in testing or is it getting ready to merge? The PR subject says "test:" so I was confused 😄
30c77ac to
1d9e4f0
Compare
- New cx-one-scan.yaml workflow runs a Checkmarx One scan (SAST/SCA/
IaC/API security/containers/SCS/ASCA) on pull_request, push
(main/master), a daily schedule, and manual dispatch
- Fetch the repo's GitHub custom properties (repo_owner, team_name,
security_champion, repo_component) via the GitHub API and apply them
as both project tags and scan tags, so Checkmarx One findings can be
filtered/owned by team without manual tagging; gracefully skips
tagging (with a warning annotation) instead of failing the scan if
the properties can't be fetched or none are set
- Pin actions/checkout to v7.0.1 and checkmarx/ast-github-action to
2.3.46
- Scope permissions at the job level (contents: read), with
permissions: {} as the workflow-level default
0a57ccd to
64dec5e
Compare
Add a workflow_call trigger (declaring the four Checkmarx secrets as required) so other repos can invoke this workflow directly via uses: Checkmarx/doss-github-actions-public/.github/workflows/cx-one-scan.yaml@<ref> instead of duplicating it.
Summary
Adds a Checkmarx One scan workflow (
cx-one-scan.yaml) for this public repo, and tags both the Checkmarx One project and each scan with this repository's GitHub custom properties (repo_owner,team_name,security_champion,repo_component), so findings in Checkmarx One can be filtered/owned by team without manual tagging.What changed
cx-one-scan.yamlruns a Checkmarx One scan (SAST/SCA/IaC/API security/containers/SCS/ASCA) onpull_request,push(main/master), a daily schedule, and manual dispatch.repos/{repo}/properties/values) to read this repo's custom properties, then passes them to the Checkmarx CLI as both--project-tags(persists on the Checkmarx One project) and--tags(applied per scan), using the repo's ownGITHUB_TOKEN— no extra permissions needed since this is a metadata-read-only call.actions/checkoutbumpedv6→v7.0.1checkmarx/ast-github-actionbumped2.3.42→2.3.46(latest)pushtrigger now also runs onmaster, for repos still using the legacy default branch nameWhy
What this achieves
repo_owner,team_name,security_champion, andrepo_component, kept in sync with GitHub on every run (no manual upkeep).checkout7.x andast-github-action2.3.43-2.3.46.master.