Skip to content

Commit 3a0c048

Browse files
committed
chore(security): pin GitHub Actions to immutable commit shas
GitHub now enforces sha_pinning_required for this repository, so every uses reference in the workflows needs to point at a full 40 character commit hash instead of a moving tag. The comments next to each hash keep the semver visible for humans and let Dependabot bump the pin when a new release ships. Also drops required_signatures from the main ruleset script because the maintainer signs commits through GitHub and does not run local GPG or SSH signing. The rule can come back once signing keys are set up and the signing workflow is documented.
1 parent 1068f74 commit 3a0c048

3 files changed

Lines changed: 14 additions & 15 deletions

File tree

.github/workflows/release.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,10 @@ jobs:
2929
runs-on: ${{ matrix.platform }}
3030

3131
steps:
32-
- uses: actions/checkout@v4
32+
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
3333

3434
- name: Install Rust stable
35-
uses: dtolnay/rust-toolchain@stable
35+
uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
3636
with:
3737
targets: ${{ matrix.rust_targets }}
3838

@@ -43,18 +43,18 @@ jobs:
4343
sudo apt-get install -y libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf
4444
4545
- name: Setup Node
46-
uses: actions/setup-node@v4
46+
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
4747
with:
4848
node-version: lts/*
4949

5050
- name: Setup Bun
51-
uses: oven-sh/setup-bun@v2
51+
uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0
5252

5353
- name: Install frontend dependencies
5454
run: bun install
5555

5656
- name: Build and publish
57-
uses: tauri-apps/tauri-action@v0
57+
uses: tauri-apps/tauri-action@84b9d35b5fc46c1e45415bdb6144030364f7ebc5 # v0.6.2
5858
env:
5959
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6060
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}

.github/workflows/test.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
typecheck:
1515
runs-on: ubuntu-22.04
1616
steps:
17-
- uses: actions/checkout@v4
17+
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
1818

1919
- name: Setup Bun
2020
run: npm install -g bun@1.3.10
@@ -28,7 +28,7 @@ jobs:
2828
lint:
2929
runs-on: ubuntu-22.04
3030
steps:
31-
- uses: actions/checkout@v4
31+
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
3232

3333
- name: Setup Bun
3434
run: npm install -g bun@1.3.10
@@ -60,15 +60,15 @@ jobs:
6060
runs-on: ${{ matrix.platform }}
6161

6262
steps:
63-
- uses: actions/checkout@v4
63+
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
6464

6565
- name: Install Rust stable
66-
uses: dtolnay/rust-toolchain@stable
66+
uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
6767
with:
6868
targets: ${{ matrix.rust_targets }}
6969

7070
- name: Rust cache
71-
uses: swatinem/rust-cache@v2
71+
uses: swatinem/rust-cache@e18b497796c12c097a38f9edb9d0641fb99eee32 # v2.9.1
7272
with:
7373
workspaces: src-tauri
7474

@@ -79,7 +79,7 @@ jobs:
7979
sudo apt-get install -y libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf
8080
8181
- name: Setup Node
82-
uses: actions/setup-node@v4
82+
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
8383
with:
8484
node-version: lts/*
8585

@@ -96,15 +96,15 @@ jobs:
9696
rust-tests:
9797
runs-on: ubuntu-22.04
9898
steps:
99-
- uses: actions/checkout@v4
99+
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
100100

101101
- name: Install Rust stable
102-
uses: dtolnay/rust-toolchain@stable
102+
uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
103103
with:
104104
components: clippy, rustfmt
105105

106106
- name: Rust cache
107-
uses: swatinem/rust-cache@v2
107+
uses: swatinem/rust-cache@e18b497796c12c097a38f9edb9d0641fb99eee32 # v2.9.1
108108

109109
- name: Install Linux dependencies
110110
run: |

scripts/setup-github-security.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ payload=$(cat <<JSON
6868
{ "type": "deletion" },
6969
{ "type": "non_fast_forward" },
7070
{ "type": "required_linear_history" },
71-
{ "type": "required_signatures" },
7271
{
7372
"type": "pull_request",
7473
"parameters": {

0 commit comments

Comments
 (0)