chore(gha): pass commenter login through env in claude.yml#40042
Merged
Conversation
Move the github.event.comment.user.login (and the fallback chain on
the deny-access step) from inline ${{ }} expansion in the script
bodies to step-level env: blocks, then read them as $COMMENTER and
process.env.COMMENTER_LOGIN respectively. Hardens the workflow
against the standard zizmor template-injection class without
changing observable behavior.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Contributor
|
Bito Automatic Review Skipped - Files Excluded |
hainenber
approved these changes
May 12, 2026
✅ Deploy Preview for superset-docs-preview ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
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.
SUMMARY
Small hardening of `.github/workflows/claude.yml`: move the `github.event.*.user.login` references off inline `${{ }}` expansion inside the shell and `actions/github-script` bodies and onto step-level `env:` blocks, then read the values as `$COMMENTER` / `process.env.COMMENTER_LOGIN`. This is the standard mitigation pattern recommended by zizmor's template-injection rule and matches the broader Superset workflow conventions.
No behavior change — the values resolved are identical, they just arrive via the runner-set environment instead of being interpolated into the script source before execution.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
N/A — workflow change only.
TESTING INSTRUCTIONS
GitHub Actions workflow files aren't unit-testable in this repo's test suite. The change is verifiable by inspection:
The allowed-users gating logic is unchanged.
ADDITIONAL INFORMATION