Skip to content

Commit 342051e

Browse files
committed
ci: add read-only workflow token permissions
Set explicit, least-privilege GitHub Actions token permissions for the CI, Coverity, Doxygen, and SSL library test workflows. The build and test jobs only need repository contents read access. The Doxygen deploy job already declares its Pages and OIDC permissions at the job level, so the workflow default can stay read-only.
1 parent c9b5f9e commit 342051e

4 files changed

Lines changed: 12 additions & 0 deletions

File tree

.github/workflows/build.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ on:
44
push:
55
pull_request:
66

7+
permissions:
8+
contents: read
9+
710
jobs:
811
clang-format:
912
name: Check code style with clang-format

.github/workflows/coverity-scan.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ on:
44
- cron: '0 20 * * *' # Daily at 20:00 UTC
55
workflow_dispatch:
66

7+
permissions:
8+
contents: read
9+
710
jobs:
811
latest:
912
# Running coverity requires the secrets.COVERITY_SCAN_TOKEN token

.github/workflows/doxygen.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ on:
33
push:
44
branches: ["master"]
55
workflow_dispatch:
6+
permissions:
7+
contents: read
8+
69
concurrency:
710
group: "pages"
811
cancel-in-progress: false

.github/workflows/test-ssllib.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
name: test_ssllib
22

3+
permissions:
4+
contents: read
5+
36
on:
47
workflow_call:
58
inputs:

0 commit comments

Comments
 (0)