Skip to content

Commit 977b8f8

Browse files
committed
ci(skills): set least-privilege workflow permissions
Add top-level contents: read permissions to main and lint-build-test workflows so GITHUB_TOKEN is least-privilege. Clears CodeQL 'workflow does not contain permissions' alerts; job-level blocks (security-events: write, contents: write) still override where needed.
1 parent bce61c6 commit 977b8f8

2 files changed

Lines changed: 6 additions & 0 deletions

File tree

.github/workflows/lint-build-test.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ name: Lint, Build, and Test
33
on:
44
workflow_call:
55

6+
permissions:
7+
contents: read
8+
69
jobs:
710
validate-changelog:
811
name: Validate changelog

.github/workflows/main.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ concurrency:
1010
group: ${{ github.workflow }}-${{ github.ref == 'refs/heads/main' && github.sha || github.ref }}
1111
cancel-in-progress: ${{ !contains(github.ref, 'refs/heads/main') }}
1212

13+
permissions:
14+
contents: read
15+
1316
jobs:
1417
check-workflows:
1518
name: Check workflows

0 commit comments

Comments
 (0)