Skip to content

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

Merged
maarten00 merged 1 commit into
mainfrom
alert-autofix-1
Aug 26, 2026
Merged

maarten00 merged 1 commit into
mainfrom
alert-autofix-1

Conversation

@maarten00

Copy link
Copy Markdown
Contributor

Potential fix for https://github.com/uxico-dev/unifi-access-api/security/code-scanning/1

Add an explicit permissions block to .github/workflows/main.yml at the workflow root (top-level), so it applies to all jobs unless overridden.
Best minimal fix without changing behavior: set:

  • contents: read

This matches CodeQL’s recommended minimal baseline and is sufficient for checkout and typical read operations. Place it after the on: block (or near the top-level metadata) before jobs: for clarity.

No imports, methods, or dependencies are needed—just YAML configuration update in the shown file.

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>
@maarten00
maarten00 marked this pull request as ready for review August 11, 2026 13:10
@codecov

codecov Bot commented Aug 11, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ All tests successful. No failed tests found.

📢 Thoughts on this report? Let us know!

@maarten00
maarten00 merged commit c8a0530 into main Aug 26, 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