Skip to content

Potential fix for code scanning alert no. 5: Workflow does not contain permissions#6

Merged
omeritzics merged 1 commit into
mainfrom
alert-autofix-5
Dec 17, 2025
Merged

Potential fix for code scanning alert no. 5: Workflow does not contain permissions#6
omeritzics merged 1 commit into
mainfrom
alert-autofix-5

Conversation

@omeritzics
Copy link
Copy Markdown
Owner

Potential fix for https://github.com/omeritzics/Updatium/security/code-scanning/5

The best practice is to specify a permissions key at the earliest applicable scope. You can set it at the workflow root (top-level, affecting all jobs), or on each job (if some jobs require different permissions). According to the CodeQL message and the nature of the actions used, the minimal set is:

permissions:
  contents: read
  security-events: write

The contents: read allows for code checkout, and security-events: write grants the minimum required for uploading SARIF files to the Security tab with github/codeql-action/upload-sarif.

You should insert this permissions block at the top level, after the name: and before the on: block, for maximum clarity and coverage. No further code or configuration is required.


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>
@omeritzics omeritzics marked this pull request as ready for review December 17, 2025 13:57
@omeritzics omeritzics merged commit 9407400 into main Dec 17, 2025
4 of 9 checks passed
@github-actions
Copy link
Copy Markdown

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@omeritzics omeritzics deleted the alert-autofix-5 branch December 21, 2025 18:38
omeritzics added a commit that referenced this pull request Feb 12, 2026
omeritzics added a commit that referenced this pull request Feb 12, 2026
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