Skip to content

Give the workflow tokens least privilege - #8

Merged
Sbussiso merged 1 commit into
masterfrom
ci/least-privilege-tokens
Sep 13, 2026
Merged

Sbussiso merged 1 commit into
masterfrom
ci/least-privilege-tokens

Conversation

@Sbussiso

Copy link
Copy Markdown
Contributor

CodeQL flagged every job in this repo's workflows with actions/missing-workflow-permissions: with no permissions block, a job inherits the repository default GITHUB_TOKEN scope, which is broader than anything here needs.

Checked what each job actually needs before narrowing — no gh CLI calls, no git push, no package publish, and actions/upload-artifact uses the runtime token rather than a contents scope. So contents: read is sufficient.

Part of a fleet-wide pass (Command Center #299 covers its 4 alerts).

🤖 Generated with Claude Code

CodeQL`s actions/missing-workflow-permissions flagged every job here: with
no permissions block a job inherits the repository default GITHUB_TOKEN
scope, which is broader than anything in this repo needs.

Checked before narrowing — no gh CLI calls, no git push, no package
publish, and actions/upload-artifact uses the runtime token rather than a
contents scope. contents: read is sufficient.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@Sbussiso
Sbussiso merged commit 02e219c into master Sep 13, 2026
4 checks passed
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.

1 participant