security: verify GitHub webhooks and isolate Chromatic secrets - #18954
security: verify GitHub webhooks and isolate Chromatic secrets#18954pillowtalk-Qy wants to merge 7 commits into
Conversation
✅ Deploy Preview for ethereumorg ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
Live CI note: GitHub created a no-job failure for the unchanged .github/workflows/claude-review-translations.yml. actionlint reproduces it on origin/dev at line 62: a comment is embedded inside the multiline job if expression and GitHub rejects the expression parser input. This is pre-existing and outside this PR diff; run: https://github.com/ethereum/ethereum-org-website/actions/runs/30701334871. It should be fixed in the release-reliability workflow follow-up, not folded into this supply-chain change. |
|
Security follow-up Evidence on the latest SHA:
The remaining CI run is awaiting fork-workflow approval: https://github.com/ethereum/ethereum-org-website/actions/runs/30709016390 Do not merge until an administrator completes both rollout blocks in the PR body: configure the matching production/repository webhook secret and verify a signed ping; rotate the exposed Chromatic token, add |
🔎 First-pass review — 🔧 Needs workSolid supply-chain hardening, but it carries external prerequisites that must be met at merge. Three parts: (1) CI hardening — adds Before merge (blocking — merging without these breaks live behavior):
Non-blocking: same AnalysisLane: tooling + code ( Checked: Routing:
|
|
Follow-up to the automated first-pass review: the code-side findings are addressed on final SHA
Final local evidence: targeted webhook tests 10/10; full unit suite 1000 passed and 1 skipped; lint, type-check, Prettier, @wackerow @pettinarip, the remaining work is administrator-only and blocks merge:
Please do not merge before those steps are complete: without the webhook secret the route deliberately fails closed, and without the new Chromatic secret the trusted Storybook publish cannot work. The invalid |
🔎 First-pass review — 🔧 Needs workRe-review of final SHA What remains is admin-only and blocks merge — merging without these breaks live behavior:
AnalysisLane: tooling + code ( Checked: Fork PR from a first-time contributor touching secrets + CI. Routing:
|
|
Admin follow-up on final SHA @wackerow @pettinarip, could you confirm whether the blocking rollout is planned or completed?
Please do not merge before those steps are confirmed: the webhook intentionally fails closed without its secret, and trusted Storybook publishing requires the replacement Secret. No additional code work is proposed on #18954. |

Risk
The good-first-issue endpoint currently accepts unauthenticated JSON and can trigger Discord notifications. The Storybook Chromatic token is also committed in
ci.yml, so copied workflows can publish against the ethereum.org project and consume its quota.This PR fails closed at both boundaries. It must not merge until the administrator rollout below is complete: a missing webhook secret intentionally returns 500, and Chromatic publishing requires repository Secrets that are intentionally unavailable to forks and Dependabot.
Changes
GitHub webhook
X-Hub-Signature-256against the exact request bytes with HMAC-SHA256 andtimingSafeEqual.Chromatic and fork boundary
secrets.CHROMATIC_STORYBOOK_TOKEN.visual-testsandpage-visual-tests) to non-draft PRs whose head repository ID and name matchethereum/ethereum-org-website.Least privilege
GITHUB_TOKENpermission tocontents: read.The duplicate
claude-review-translations.ymlfix has been removed from this PR and remains owned by #18953. The final diff contains only the security work above and its tests.Administrator rollout (blocking)
GitHub webhook, before merge
GITHUB_WEBHOOK_SECRET./api/gfi-issues-webhook.Setting the environment and webhook secret before deployment is backward-compatible: the current endpoint ignores the new signature header.
Chromatic, before merge
b4dab9c780aaece3d569aad708c0abe05f434b3eso the non-secret checks can execute.ethereum/ethereum-org-websitebranch so the trusted visual path can be exercised.CHROMATIC_STORYBOOK_TOKEN.If a Chromatic App check is required, fork PRs cannot merge directly because they intentionally receive no Chromatic secret or result. The secure workflow is to move the reviewed commit to an internal branch and run Chromatic there. Do not create a privileged
pull_request_targetworkflow that marks an untested fork SHA successful.I could not inspect Actions secrets, webhook configuration, or fork approval policy with contributor credentials, so these remain explicit administrator checks.
Test evidence (final SHA)
pnpm lint: passed.pnpm type-check: passed.USE_MOCK_DATA=true NEXT_PUBLIC_BUILD_LOCALES=en pnpm build: passed; 411 static pages generated.git diff --check: passed.actionlintv1.7.12: no new findings versusorigin/dev; both report the same pre-existing Lighthousemanifestoutput typing warning.dev: four files; noclaude-review-translations.ymldiff.Rollback
CHROMATIC_SKIP=**emergency control, then adjust the trusted-source condition or permissions while retaining Secret references. Never restore the exposed token.Unresolved
devversion ofclaude-review-translations.ymlhas a pre-existing invalid multilineifexpression. Its fix is deliberately excluded here and remains in ci: enforce a production release gate #18953.