ci: add zizmor to lint-actions#37720
Merged
Merged
Conversation
- Add `persist-credentials: false` to every `actions/checkout` - Pin floating-tag service images to `tag@sha256:...` in pull-db-tests - Move `github.ref`, `github.ref_name`, secrets, and step outputs out of `run:` blocks into `env:` to prevent template-injection - Disable `setup-go` cache in release workflows (cache-poisoning) - Inline-ignore cache-poisoning on `setup-node`'s pnpm cache (per-branch scope, only maintainer pushes write to it) - Wire `zizmor` into `make lint-actions` Co-Authored-By: Claude (Opus 4.7) <noreply@anthropic.com>
zizmor to lint-actions and harden workflowszizmor to lint-actions
Co-Authored-By: Claude (Opus 4.7) <noreply@anthropic.com>
Co-Authored-By: Claude (Opus 4.7) <noreply@anthropic.com>
…edium Revert the artipacked persist-credentials changes, the explicit setup-go cache option, and the cache-poisoning inline ignores -- all low-confidence findings now hidden globally via the new --min-confidence=medium flag in the Makefile. Keep the env-var extractions for readability and the image digest pins for unpinned-images (high confidence). Co-Authored-By: Claude (Opus 4.7) <noreply@anthropic.com>
silverwind
commented
May 16, 2026
Signed-off-by: silverwind <me@silverwind.io>
Contributor
There was a problem hiding this comment.
Pull request overview
Adds the zizmor GitHub Actions security linter to make lint-actions (at --min-confidence=medium) and resolves all remaining findings by pinning floating service-container images to digests and moving GitHub expressions / secrets out of run: blocks into env: blocks.
Changes:
- Add
zizmor>=1.25.1as a Python dev dependency and run it viauv run --frozenin thelint-actionsMakefile target (now also depends on.venv). - In release workflows, move
secrets.*,steps.*.outputs,github.ref, andgithub.ref_namereferences from inline${{ … }}interpolations intoenv:blocks and reference them as shell variables (quoted). - In
pull-db-tests.yml, pin floating:latestservice-container images (gitea/test-openldap,redis,azurite,tabascoterrier/docker-imap-devel) totag@sha256:…digests.
Reviewed changes
Copilot reviewed 6 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| pyproject.toml | Adds zizmor>=1.25.1 to dev dependencies. |
| uv.lock | Lockfile entries for zizmor 1.25.1 wheels/sdist. |
| Makefile | lint-actions now requires .venv and runs zizmor after actionlint. |
| .github/workflows/release-tag-version.yml | Moves secrets/refs into env: and pins shell vars; no behavior change. |
| .github/workflows/release-tag-rc.yml | Same env-block refactor for the RC release workflow. |
| .github/workflows/release-nightly.yml | Same env-block refactor for nightly binary + container jobs. |
| .github/workflows/pull-db-tests.yml | Pins :latest service images to @sha256: digests for ldap/redis/azurite/smtpimap. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-Authored-By: Claude (Opus 4.7) <noreply@anthropic.com>
Co-Authored-By: Claude (Opus 4.7) <noreply@anthropic.com>
Co-Authored-By: Claude (Opus 4.7) <noreply@anthropic.com>
Co-Authored-By: Claude (Opus 4.7) <noreply@anthropic.com>
lunny
approved these changes
May 16, 2026
bircni
approved these changes
May 16, 2026
silverwind
added a commit
to silverwind/gitea
that referenced
this pull request
May 18, 2026
* origin/main: (39 commits) fix: Add missed token scope checking (go-gitea#37735) chore: Use giteabot instead of backporter (go-gitea#37422) fix: Allow direct commits for unprotected files with push restrictions (go-gitea#37657) chore: Conventional adjustments (go-gitea#37677) chore(db): introduce db.Session and db.EngineMigration interfaces (go-gitea#37746) fix(migrations): preserve unique constraints in v334 sync (go-gitea#37743) feat(web): also display PR counts in repo list (go-gitea#37739) feat: execute post run cleanup when workflow is cancelled (go-gitea#37275) fix(actions): wrong assumption that run id always >= job id (go-gitea#37737) fix(icon): use repo-forked icon to display forks count (go-gitea#37731) fix(oauth): strengthen PKCE validation and refresh token replay protection (go-gitea#37706) fix(web): enforce token scopes on raw, media, and attachment downloads (go-gitea#37698) feat: Add bypass allowlist for branch protection (go-gitea#36514) refactor(glob): use strings.Builder for regexp compilation (go-gitea#37730) feat(oauth): Support AWS Cognito OAuth2 provider (go-gitea#37607) feat: Add default PR branch update style setting (go-gitea#37410) refactor: move `workflowpattern` into `modules/actions` (go-gitea#37717) ci: add `zizmor` to `lint-actions` (go-gitea#37720) chore(doctor): remove four obsolete doctor check implementations (go-gitea#37728) chore(renovate): enable dockerfile manager (go-gitea#37719) ... # Conflicts: # modules/globallock/locker_test.go
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.
Adds zizmor to
make lint-actionswith--min-confidence=medium. Fixes the remaining findings:pull-db-tests.ymltotag@sha256:digestgithub.ref/github.ref_name(and surrounding secrets/step outputs for consistency) out ofrun:intoenv:This PR was written with the help of Claude Opus 4.7