From 6f75f7a59c73aec61cd2b2b45440f9bd725c134f Mon Sep 17 00:00:00 2001 From: Dotta Date: Wed, 7 Oct 2026 16:36:00 -0500 Subject: [PATCH] ci(hermes): supply the selected Google qualification key Map GEMINI_API_KEY only for the selected paid matrix credential. Extend the trusted-workflow credential checks to prevent ambient Google secrets in unapproved workflows. This fixes the reviewed Google cells startup failure. Validation: all 15 workflow security tests, actionlint, and diff checks pass. Co-Authored-By: Paperclip --- .github/workflows/runner-full-stack-e2e.yml | 1 + doc/plans/2026-10-06-hermes-native-runner.md | 6 ++++++ tests/runner-e2e/workflow-security.test.ts | 3 ++- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/runner-full-stack-e2e.yml b/.github/workflows/runner-full-stack-e2e.yml index b9ec393f1a..66b8de5fb0 100644 --- a/.github/workflows/runner-full-stack-e2e.yml +++ b/.github/workflows/runner-full-stack-e2e.yml @@ -1079,6 +1079,7 @@ jobs: ANTHROPIC_API_KEY: ${{ matrix.credentialName == 'ANTHROPIC_API_KEY' && secrets.ANTHROPIC_API_KEY || '' }} OPENROUTER_API_KEY: ${{ matrix.credentialName == 'OPENROUTER_API_KEY' && secrets.OPENROUTER_API_KEY || '' }} XAI_API_KEY: ${{ matrix.credentialName == 'XAI_API_KEY' && secrets.XAI_API_KEY || '' }} + GEMINI_API_KEY: ${{ matrix.credentialName == 'GEMINI_API_KEY' && secrets.GEMINI_API_KEY || '' }} GROK_AUTH_JSON: ${{ matrix.credentialName == 'GROK_AUTH_JSON' && secrets.GROK_AUTH_JSON || '' }} DAYTONA_API_KEY: ${{ matrix.environmentId == 'daytona' && secrets.DAYTONA_API_KEY || '' }} PAPERCLIP_E2E_DAYTONA_IMAGE: ${{ needs.daytona_image.outputs.image }} diff --git a/doc/plans/2026-10-06-hermes-native-runner.md b/doc/plans/2026-10-06-hermes-native-runner.md index 61d3548832..8a2ac44a9a 100644 --- a/doc/plans/2026-10-06-hermes-native-runner.md +++ b/doc/plans/2026-10-06-hermes-native-runner.md @@ -590,3 +590,9 @@ passed. The five verified encrypted cloud proofs are preserved; the disposable EC2 instance was terminated and its unused role, instance profile and security group removed. No local Docker was used. These fixture refinements require fresh current-head CI and review; they do not complete release qualification. + +Fresh review found that the paid workflow did not supply the new Google cells' +required Gemini key. The key is now mapped only when the selected matrix cell +requires it, and the workflow credential-boundary regression covers it. All 15 +workflow tests and actionlint pass. Another current-head review and CI run are +required after this correction. diff --git a/tests/runner-e2e/workflow-security.test.ts b/tests/runner-e2e/workflow-security.test.ts index be176bcaa2..d6fad7e81a 100644 --- a/tests/runner-e2e/workflow-security.test.ts +++ b/tests/runner-e2e/workflow-security.test.ts @@ -609,6 +609,7 @@ describe("public repository paid workflow security", () => { ANTHROPIC_API_KEY: "matrix.credentialName == 'ANTHROPIC_API_KEY'", OPENROUTER_API_KEY: "matrix.credentialName == 'OPENROUTER_API_KEY'", XAI_API_KEY: "matrix.credentialName == 'XAI_API_KEY'", + GEMINI_API_KEY: "matrix.credentialName == 'GEMINI_API_KEY'", GROK_AUTH_JSON: "matrix.credentialName == 'GROK_AUTH_JSON'", DAYTONA_API_KEY: "matrix.environmentId == 'daytona'", })) { @@ -637,7 +638,7 @@ describe("public repository paid workflow security", () => { ); const providerSecretReferences = [ ...contents.matchAll( - /secrets(?:\.(?:OPENAI_API_KEY|ANTHROPIC_API_KEY|OPENROUTER_API_KEY|XAI_API_KEY|GROK_AUTH_JSON|DAYTONA_API_KEY)\b|\[['"](?:OPENAI_API_KEY|ANTHROPIC_API_KEY|OPENROUTER_API_KEY|XAI_API_KEY|GROK_AUTH_JSON|DAYTONA_API_KEY)['"]\])/g, + /secrets(?:\.(?:OPENAI_API_KEY|ANTHROPIC_API_KEY|OPENROUTER_API_KEY|XAI_API_KEY|GEMINI_API_KEY|GROK_AUTH_JSON|DAYTONA_API_KEY)\b|\[['"](?:OPENAI_API_KEY|ANTHROPIC_API_KEY|OPENROUTER_API_KEY|XAI_API_KEY|GEMINI_API_KEY|GROK_AUTH_JSON|DAYTONA_API_KEY)['"]\])/g, ), ]; if (providerSecretReferences.length > 0) {