Skip to content

Potential fix for code scanning alert no. 2: Workflow does not contain permissions#404

Merged
wwade merged 1 commit into
mainfrom
alert-autofix-2
May 11, 2026
Merged

Potential fix for code scanning alert no. 2: Workflow does not contain permissions#404
wwade merged 1 commit into
mainfrom
alert-autofix-2

Conversation

@wwade
Copy link
Copy Markdown
Owner

@wwade wwade commented May 11, 2026

Potential fix for https://github.com/wwade/jobrunner/security/code-scanning/2

Add an explicit top-level permissions block in .github/workflows/check.yml so all jobs inherit minimal access.
Best fix without changing functionality: set:

  • contents: read (needed for repository checkout)
  • optionally packages: read only if package registry reads are required; not clearly required here, so omit for least privilege.

Because neither job needs write capabilities, no job-level overrides are necessary. Place permissions: after the on: block (or before jobs:) so it applies workflow-wide.

Suggested fixes powered by Copilot Autofix. Review carefully before merging.

…n permissions

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
@wwade wwade marked this pull request as ready for review May 11, 2026 19:02
@wwade wwade merged commit d7f8b7b into main May 11, 2026
10 checks passed
@wwade wwade deleted the alert-autofix-2 branch May 11, 2026 19:21
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