Skip to content

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

Merged
vladd-bit merged 1 commit into
mainfrom
alert-autofix-6
Nov 20, 2026
Merged

vladd-bit merged 1 commit into
mainfrom
alert-autofix-6

Conversation

@vladd-bit

Copy link
Copy Markdown
Member

Potential fix for https://github.com/CogStack/cogstack-platform/security/code-scanning/6

Add an explicit permissions block to the workflow so GITHUB_TOKEN is constrained to least privilege.
Best fix here: define workflow-level permissions immediately after on: (or before jobs:) with:

  • contents: read

This preserves existing behavior (checkout and docs build still work) while documenting and enforcing minimal access for all jobs in this workflow.

File to edit: .github/workflows/build_docs.yml
Change region: between the on: block and defaults: (or before jobs:).
No imports, methods, or dependencies are needed.

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>
@vladd-bit vladd-bit changed the title Potential fix for code scanning alert no. 6: Workflow does not contain permissions chore: Potential fix for code scanning alert no. 6: Workflow does not contain permissions Nov 20, 2026
@vladd-bit
vladd-bit marked this pull request as ready for review November 20, 2026 10:05
@vladd-bit
vladd-bit merged commit 1a9f72b into main Nov 20, 2026
5 of 7 checks passed
@vladd-bit
vladd-bit deleted the alert-autofix-6 branch November 20, 2026 10:05
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