Skip to content

Commit 9167d0b

Browse files
authored
chore(ci): add explicit least-privilege workflow permissions (#573)
Added explicit permissions blocks to GitHub Actions workflows to satisfy CodeQL actions/missing-workflow-permissions. (See the [Security tab on Github](https://github.com/apache/iceberg-cpp/security/code-scanning)) Defaulted workflows to `contents: read`.
1 parent dbec245 commit 9167d0b

File tree

3 files changed

+10
-0
lines changed

3 files changed

+10
-0
lines changed

.github/workflows/codeql.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,15 @@ on:
2929
schedule:
3030
- cron: '16 4 * * 1'
3131

32+
permissions:
33+
contents: read
34+
3235
jobs:
3336
analyze:
3437
name: Analyze Actions
3538
runs-on: ubuntu-latest
3639
permissions:
40+
contents: read
3741
security-events: write
3842
packages: read
3943

.github/workflows/license_check.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@ name: "Run License Check"
1919

2020
on: pull_request
2121

22+
permissions:
23+
contents: read
24+
2225
jobs:
2326
license-check:
2427
name: "License Check"

.github/workflows/pre-commit.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@ on:
2424
- '**'
2525
- '!dependabot/**'
2626

27+
permissions:
28+
contents: read
29+
2730
jobs:
2831
pre-commit:
2932
runs-on: ubuntu-24.04

0 commit comments

Comments
 (0)