Skip to content

Commit b7c02ea

Browse files
Copilotpelikhangithub-actions[bot]
authored
fix: move sink-visibility to env var to prevent zizmor template-injection (#48589)
* Initial plan * fix: move sink-visibility to env var to prevent zizmor template-injection - Change sinkVisibilityRuntimeExpr from a raw ${{ }} expression in the run: heredoc to ${GH_AW_SINK_VISIBILITY} shell variable reference - Add GH_AW_SINK_VISIBILITY env var to Start MCP Gateway step's env: block, set from ${{ toJSON(steps.determine-automatic-lockdown.outputs.visibility) }} - Add -e GH_AW_SINK_VISIBILITY to MCP gateway Docker container flags - Add GH_AW_SINK_VISIBILITY to buildAddedGatewayEnvVarSet to prevent duplicate emission - Add --persona auditor to internal zizmor invocation - Update test to check for GH_AW_SINK_VISIBILITY instead of old expression - Regenerate 263 lock files via make recompile Fixes #48565 Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com> * fix: set GH_AW_SINK_VISIBILITY for gh-proxy mode workflows The initial fix only added GH_AW_SINK_VISIBILITY to the env block when 'github' was present in mcpTools. For gh-proxy mode workflows, GitHub is excluded from mcpTools (because it's handled via CLI proxy instead of MCP server), but determine-automatic-lockdown still runs and sink-visibility is still emitted in the MCP gateway config JSON. Move the GH_AW_SINK_VISIBILITY env var assignment to check tools["github"] directly (same condition as generateGitHubMCPLockdownDetectionStep), so all workflows with the GitHub tool get the env var regardless of mode. Also update golden test files to reflect the new env var and docker flag. Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com> * fix: remove toJSON() from GH_AW_SINK_VISIBILITY to fix double-encoding Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com> * Add changeset for sink visibility fix * fix: rebase PR 48632 fixes - add sinkVisibilityEnvVar constant, sorted policy iteration, and case string handler Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Peli de Halleux <pelikhan@users.noreply.github.com>
1 parent 9503dc5 commit b7c02ea

278 files changed

Lines changed: 1565 additions & 1228 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.changeset/patch-move-sink-visibility-env-var.md

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/workflows/ab-testing-advisor.lock.yml

Lines changed: 5 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/workflows/ace-editor.lock.yml

Lines changed: 5 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/workflows/agent-performance-analyzer.lock.yml

Lines changed: 6 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)