summaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorAlex <[email protected]>2022-09-29 08:44:28 +0300
committerGitHub <[email protected]>2022-09-29 01:44:28 -0400
commite0294dab507c0391f3ab5973185b4fedb0d00e27 (patch)
treee188894530f88d9f204adbdf7b3dbad7c9df5c8e /.github
parent64a6297840c626d1cca85eff935353ede72e3d0d (diff)
GitHub Workflows security hardening (#6472)
* build: harden action_tools.yml permissions Signed-off-by: Alex <[email protected]> * build: harden action.yml permissions Signed-off-by: Alex <[email protected]> * build: harden action_utest.yml permissions Signed-off-by: Alex <[email protected]> Signed-off-by: Alex <[email protected]>
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/action.yml3
-rw-r--r--.github/workflows/action_tools.yml3
-rw-r--r--.github/workflows/action_utest.yml3
3 files changed, 9 insertions, 0 deletions
diff --git a/.github/workflows/action.yml b/.github/workflows/action.yml
index e48dd9b6b1..ef3b1f59fb 100644
--- a/.github/workflows/action.yml
+++ b/.github/workflows/action.yml
@@ -21,6 +21,9 @@ on:
- '**/README.md'
- '**/README_zh.md'
+permissions:
+ contents: read # to fetch code (actions/checkout)
+
jobs:
build:
runs-on: ubuntu-latest
diff --git a/.github/workflows/action_tools.yml b/.github/workflows/action_tools.yml
index 64f8299c26..09cf71e26a 100644
--- a/.github/workflows/action_tools.yml
+++ b/.github/workflows/action_tools.yml
@@ -27,6 +27,9 @@ on:
- '**/*.h'
- '**/*.cpp'
+permissions:
+ contents: read # to fetch code (actions/checkout)
+
jobs:
test:
runs-on: ubuntu-latest
diff --git a/.github/workflows/action_utest.yml b/.github/workflows/action_utest.yml
index 1cf4be1220..c84fe004e0 100644
--- a/.github/workflows/action_utest.yml
+++ b/.github/workflows/action_utest.yml
@@ -21,6 +21,9 @@ on:
- '**/README.md'
- '**/README_zh.md'
+permissions:
+ contents: read # to fetch code (actions/checkout)
+
jobs:
test:
runs-on: ubuntu-latest