Skip to content

Commit 0c1a3d9

Browse files
[StepSecurity] ci: Harden GitHub Actions (#13136)
Signed-off-by: StepSecurity Bot <[email protected]>
1 parent b1eb1fd commit 0c1a3d9

6 files changed

+20
-2
lines changed

.github/workflows/assign-reviewers.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
assign-reviewers:
1313
runs-on: ubuntu-latest
1414
steps:
15-
- uses: trask/component-owners@main
15+
- uses: trask/component-owners@02dfde3c03025c064cc6961975e28a42e81c394a # main
1616
with:
1717
# this repository is using this action to request doc review
1818
assign-owners: false

.github/workflows/label.yml

+3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
name: Labeler
22
on: [pull_request_target]
33

4+
permissions:
5+
contents: read
6+
47
jobs:
58
label:
69

.github/workflows/prepare-patch-release.yml

+5
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,13 @@ name: Prepare patch release
22
on:
33
workflow_dispatch:
44

5+
permissions:
6+
contents: read
7+
58
jobs:
69
prepare-patch-release:
10+
permissions:
11+
contents: write # for Git to git push
712
runs-on: ubuntu-latest
813
steps:
914
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

.github/workflows/prepare-release-branch.yml

+7
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@ name: Prepare release branch
22
on:
33
workflow_dispatch:
44

5+
permissions:
6+
contents: read
7+
58
jobs:
69
prereqs:
710
runs-on: ubuntu-latest
@@ -21,6 +24,8 @@ jobs:
2124
fi
2225
2326
create-pull-request-against-release-branch:
27+
permissions:
28+
contents: write # for Git to git push
2429
runs-on: ubuntu-latest
2530
needs:
2631
- prereqs
@@ -74,6 +79,8 @@ jobs:
7479
--base $RELEASE_BRANCH_NAME
7580
7681
create-pull-request-against-main:
82+
permissions:
83+
contents: write # for Git to git push
7784
runs-on: ubuntu-latest
7885
needs:
7986
- prereqs

.github/workflows/publish-petclinic-benchmark-image.yml

+3
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@ on:
77
- main
88
workflow_dispatch:
99

10+
permissions:
11+
contents: read
12+
1013
jobs:
1114
publish:
1215
runs-on: ubuntu-latest

.github/workflows/reusable-markdown-link-check.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
steps:
1313
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
1414

15-
- uses: lycheeverse/lychee-action@v2
15+
- uses: lycheeverse/lychee-action@f796c8b7d468feb9b8c0a46da3fac0af6874d374 # v2.2.0
1616
with:
1717
# excluding links to pull requests and issues is done for performance
1818
args: >

0 commit comments

Comments
 (0)