Secure GHA with zizmor - #400
Merged
Merged
Conversation
gforcada
force-pushed
the
384-add-zizmor
branch
2 times, most recently
from
August 2, 2026 13:28
c28c6e5 to
ecd12ba
Compare
Member
|
@gforcada thanks for the heads up. I need to review all the existing workflows and actions when it comes to permissions and versions |
gforcada
force-pushed
the
384-add-zizmor
branch
2 times, most recently
from
August 7, 2026 18:02
422b455 to
35b41fa
Compare
gforcada
force-pushed
the
384-add-zizmor
branch
from
August 7, 2026 18:10
35b41fa to
f465886
Compare
ericof
reviewed
Aug 7, 2026
| shell: bash | ||
| run: | | ||
| uvx ruff@${{ inputs.version-ruff }} format --diff | ||
| uvx ruff@${INPUTS_VERSION_RUFF} format --diff |
Member
There was a problem hiding this comment.
I do not understand the indirection, but you got my attention here.
Member
Author
There was a problem hiding this comment.
It's about template injection: https://docs.zizmor.sh/audits/#template-injection
Member
There was a problem hiding this comment.
I will also add this checks to cookieplone-templates.
This was referenced Aug 8, 2026
Closed
ericof
added a commit
that referenced
this pull request
Aug 12, 2026
…uts (#405) * Document every shared workflow and the quoting rules for options inputs Since #400 the options-style inputs are expanded by the shell from an environment variable instead of being substituted into the script as literal text. Unquoted parameter expansion still splits on whitespace, but it does not perform quote removal, so quote characters in the value end up as literal characters in the argument. A value such as zpretty-options: '--extend-exclude "/rss/(rss\.xml|search-rss)\.pt$"' now reaches zpretty with the double quotes attached, the pattern matches nothing, and the excluded files are checked after all. The reference documentation recommended exactly that form. Describe the actual behaviour in a dedicated section, mark the two affected inputs, and fix the example to the unquoted form. While here, close the remaining gaps in the same reference: - Document the inputs of all fifteen reusable workflows. Only backend-lint had a table. - Add the five workflows that were missing entirely: coverage, circular, dependencies, qa and release_ready. - Correct the three composite action tables, which between them omitted five inputs and misdescribed setup_uv. - Correct the container registry secret names, documented as registry-username and registry-password rather than username and password. - Distinguish container-image-build from container-image-push by their shared registry-backed build cache. - Record that reusable workflows declare no permissions of their own, and state what frontend-storybook needs from its caller in order to deploy. Closes #404 * Let Dependabot reach the composite actions For the github-actions ecosystem, directory "/" covers .github/workflows and a root-level action.yml. Our composite actions live in .github/actions/<name>/action.yml, which is neither, so their dependencies were never updated. The dependency graph confirms the blind spot: actions/setup-node does not appear at all, and astral-sh/setup-uv appears only at the versions used by the workflows, never at the version pinned inside the composite actions. Every commit touching .github/actions since it was created has been a manual bump. Use the directories key so the composite actions are scanned as well.
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.
Part of #384
Note
zizmoreither as a GHA nor within pre-commit or such. The reason being thatzizmorcomplains, rightfully so, about GHA not using hash-pinning, but can not update it.pinact or tools like that can, but need to be checked first how to integrate them.
While we discuss and prototype how to best integrate it, the first quick fixes from
zizmorare already worth merging IMHO.@ericof if you run
uvx zizmor .in this repository there are a few warning about some actions that you added, could you have a look whenever you have time, they are about token permissions and their scope, which I don't have enough knowledge about the actions themselves to make an estimated guess on what would be the proper fix.