Skip to content

Commit 3fe1b13

Browse files
committed
chore(ci): pin GitHub Actions to commit SHAs
Replaces moving tag references with full commit SHAs and trailing semver comments. Defends against tag-repointing supply-chain attacks if a third- party action maintainer is compromised.
1 parent af57aa3 commit 3fe1b13

3 files changed

Lines changed: 10 additions & 11 deletions

File tree

.github/workflows/ci.yml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,12 @@ jobs:
3333

3434
steps:
3535
- name: Checkout code
36-
uses: actions/checkout@v6
36+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
3737
with:
3838
fetch-depth: 0
3939

4040
- name: Setup Node.js ${{ matrix.node-version }}
41-
uses: actions/setup-node@v6
41+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
4242
with:
4343
node-version: ${{ matrix.node-version }}
4444
cache: 'npm'
@@ -91,10 +91,9 @@ jobs:
9191

9292
steps:
9393
- name: Checkout code
94-
uses: actions/checkout@v6
95-
94+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
9695
- name: Setup Node.js
97-
uses: actions/setup-node@v6
96+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
9897
with:
9998
node-version: '20.x'
10099
cache: 'npm'
@@ -108,7 +107,7 @@ jobs:
108107
NODE_OPTIONS: --max-old-space-size=4096
109108

110109
- name: Upload coverage to Codecov
111-
uses: codecov/codecov-action@v6
110+
uses: codecov/codecov-action@57e3a136b779b570ffcdbf80b3bdc90e7fab3de2 # v6.0.0
112111
with:
113112
token: ${{ secrets.CODECOV_TOKEN }}
114113
file: ./coverage/lcov.info

.github/workflows/manual-release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,13 @@ jobs:
2626

2727
steps:
2828
- name: Checkout
29-
uses: actions/checkout@v4
29+
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
3030
with:
3131
fetch-depth: 0
3232
token: ${{ secrets.GITHUB_TOKEN }}
3333

3434
- name: Setup Node.js
35-
uses: actions/setup-node@v4
35+
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
3636
with:
3737
node-version: "lts/*"
3838
registry-url: 'https://registry.npmjs.org'

.github/workflows/release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@ jobs:
1818

1919
steps:
2020
- name: Checkout
21-
uses: actions/checkout@v4
21+
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
2222
with:
2323
fetch-depth: 0
2424

2525
- name: Setup Node.js
26-
uses: actions/setup-node@v4
26+
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
2727
with:
2828
node-version: "20.x"
2929
registry-url: "https://npm.pkg.github.com"
@@ -74,7 +74,7 @@ jobs:
7474
echo "Release notes extracted"
7575
7676
- name: Create GitHub Release
77-
uses: softprops/action-gh-release@v3
77+
uses: softprops/action-gh-release@b4309332981a82ec1c5618f44dd2e27cc8bfbfda # v3.0.0
7878
with:
7979
tag_name: ${{ github.ref_name }}
8080
name: Release ${{ github.ref_name }}

0 commit comments

Comments
 (0)