-
Notifications
You must be signed in to change notification settings - Fork 37
Closed
Labels
enhancementNew feature or requestNew feature or requestgithub_actionsPull requests that update GitHub Actions codePull requests that update GitHub Actions code
Description
The Manage stale issues and PRs workflow is already well-secured and not exposed to the recent GitHub Actions exploit class (e.g. HackerBot-Claw). However, we can further improve it by applying stricter least-privilege permissions.
Proposed change
Replace the top-level permissions:
permissions:
contents: readwith:
permissions: {}Why
- The workflow does not require repository content access
- Permissions are already correctly scoped at the job level:
issues: write pull-requests: write
- Reduces the default token scope
- Aligns with GitHub Actions security best practices
Impact
- ✅ No functional change expected
- ✅ Slightly reduced attack surface
- ✅ Clearer security posture
Notes
The workflow is already safe against untrusted code execution risks (no pull_request_target, no code execution), this is just a defense-in-depth improvement.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestgithub_actionsPull requests that update GitHub Actions codePull requests that update GitHub Actions code