Skip to content

SRE-901: Stop handing CI more Vault reach than it uses - #405

Merged
TimDiekmann merged 1 commit into
mainfrom
t/sre-901-harden-the-centralized-renovate-workflow-against-compromised
Aug 5, 2026
Merged

SRE-901: Stop handing CI more Vault reach than it uses#405
TimDiekmann merged 1 commit into
mainfrom
t/sre-901-harden-the-centralized-renovate-workflow-against-compromised

Conversation

@TimDiekmann

Copy link
Copy Markdown
Member

Applies the CI Vault narrowing from hashintel/hash#9160 to this repo.

  • secrets: inherit dropped from the renovate job. The pinned reusable workflow reads no secrets.* — the Vault address comes from vars.VAULT_ADDR, a repo variable, which secrets: inherit never carried.
  • contents: writeread. The reusable workflow declares contents: read for itself, so the Renovate job's token is already read-only in the current scheduled runs. The caller-side write only reached this workflow's own validate job, which checks out and runs jq/actionlint.

Related links

What tests cover this?

actionlint v1.7.12 on the changed file: clean. Renovate is proven green under contents: read, since that is already its effective permission today.

@TimDiekmann TimDiekmann self-assigned this Aug 5, 2026
@TimDiekmann
TimDiekmann marked this pull request as ready for review August 5, 2026 10:42
Copilot AI lite review requested due to automatic review settings August 5, 2026 10:42
@cursor

cursor Bot commented Aug 5, 2026

Copy link
Copy Markdown

PR Summary

Low Risk
Permission and secret-scoping changes only; Renovate already ran with read-only contents, and validate only needs checkout plus linting.

Overview
Reduces CI token and secret exposure in the housekeeping workflow to match the least privilege the Renovate path already effectively had.

Workflow-level contents: write is changed to contents: read, so the default GITHUB_TOKEN for jobs in this file (including validate on PRs) is no longer write-capable. secrets: inherit is removed from the renovate job that calls hashintel/.github’s housekeeping-dependencies.yml, since that reusable workflow does not consume caller secrets (Vault uses vars.VAULT_ADDR instead).

Reviewed by Cursor Bugbot for commit f89fee4. Bugbot is set up for automated code reviews on this repo. Configure here.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Reduces the default GitHub Actions token scope for the housekeeping workflow to match the Renovate reusable workflow’s actual needs, limiting CI’s Vault exposure and repository write permissions.

Changes:

  • Downgrades workflow permissions.contents from write to read.
  • Removes secrets: inherit from the renovate job invoking the pinned reusable workflow.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@TimDiekmann
TimDiekmann added this pull request to the merge queue Aug 5, 2026
Merged via the queue into main with commit 6643f5a Aug 5, 2026
9 checks passed
@TimDiekmann
TimDiekmann deleted the t/sre-901-harden-the-centralized-renovate-workflow-against-compromised branch August 5, 2026 10:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants