ci: Run zizmor on GitHub Actions and fix security findings
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 461
- Forks
- 277
- Avg merge
- 16h 48m
- Merged PRs (30d)
- 95
Description
Description
Run zizmor, a static analysis tool for GitHub Actions, on this repository's workflows to identify and fix security issues. Add zizmor as a CI check.
This follows the same work done in tektoncd/pipeline#9667.
What needs to be done
-
Run
zizmor --fix=all .to auto-fix findings:- Add
persist-credentials: falseto allactions/checkoutsteps (artipacked) - Fix template injection by replacing
${{ }}inrun:blocks with shell env vars (template-injection)
- Add
-
Add zizmor CI workflow (
.github/workflows/zizmor.yaml) that runs on pushes to main and PRs, uploading SARIF results to GitHub Advanced Security -
Fix remaining non-auto-fixable findings manually:
- Scope permissions to job level instead of workflow level (excessive-permissions)
- Fix template injection in
github-scriptsteps usingprocess.envpattern (template-injection) - Replace third-party actions with
ghCLI where possible (superfluous-actions)
-
File follow-up issues for any remaining findings that require broader changes (e.g.,
secrets-outside-env,secrets-inherit)
Reference
- zizmor docs: https://docs.zizmor.sh/
- Reference PR: https://github.com/tektoncd/pipeline/pull/9667
/kind cleanup
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running zizmor --fix=all . against the repository's GitHub Actions workflows and review the remaining findings. Add .github/workflows/zizmor.yaml for pushes to main and pull requests, including SARIF upload, then address the listed permissions, template-injection, and superfluous-action findings. Done means the CI check runs and remaining broader findings have follow-up issues.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions
- Domain
- ci-cd, security
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100