Skip to content

ci: apply least-privilege token to smoke-test workflow - #41

Merged
yeongseon merged 1 commit into
mainfrom
ci/smoke-least-privilege
Aug 13, 2026
Merged

ci: apply least-privilege token to smoke-test workflow#41
yeongseon merged 1 commit into
mainfrom
ci/smoke-least-privilege

Conversation

@yeongseon

Copy link
Copy Markdown
Contributor

Summary

  • Add an explicit permissions: contents: read block to the Smoke Tests workflow (was inheriting the repo default write token).
  • Set persist-credentials: false on actions/checkout so GITHUB_TOKEN is not stored in .git/config.

Why

make verify executes untrusted PR-authored example .py files. With the default write token persisted into .git/config, that code could read the token and push to the repo or approve PRs. Read-only + no credential persistence closes this escalation path. No secrets are referenced by the workflow, so functionality is unaffected.

Closes #40

Add an explicit read-only permissions block and disable checkout
credential persistence so the untrusted PR example code run by
`make verify` cannot reach a write-scoped GITHUB_TOKEN.

Closes #40
@yeongseon
yeongseon merged commit 02970b9 into main Aug 13, 2026
6 checks passed
@yeongseon
yeongseon deleted the ci/smoke-least-privilege branch August 13, 2026 11:27
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.

chore: apply least-privilege GITHUB_TOKEN to smoke-test workflow

1 participant