Skip to content

Commit 4759875

Browse files
committed
Use commit-hashes to refer to github actions, not manipulatible tags
Dependabot will propose updates to the used versions nonetheless. This is motivated by a recent case in which a github action was compromised and manipulated tags to point to malicious code <https://www.stepsecurity.io/blog/harden-runner-detection-tj-actions-changed-files-action-is-compromised>.
1 parent 0f2a907 commit 4759875

File tree

7 files changed

+22
-22
lines changed

7 files changed

+22
-22
lines changed

.github/workflows/bot-create-manual-reminder.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,4 @@ jobs:
1515

1616
steps:
1717
- name: 👀 check for reminder
18-
uses: agrc/create-reminder-action@v1
18+
uses: agrc/create-reminder-action@9ff30cde74284045941af16a04362938957253b1 # v1.1.17

.github/workflows/bot-manual-reminder.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,4 @@ jobs:
1515

1616
steps:
1717
- name: check reminders and notify
18-
uses: agrc/reminder-action@v1
18+
uses: agrc/reminder-action@96f2ec2e1a7a53ead156504922e9bc36d64f49ee # v1.0.16

.github/workflows/browser_tests.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,18 +45,18 @@ jobs:
4545

4646
steps:
4747
- name: Checkout code
48-
uses: actions/checkout@v4
48+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
4949

5050
- name: Setup PHP
51-
uses: shivammathur/setup-php@v2
51+
uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0
5252
with:
5353
php-version: ${{ matrix.php }}
5454
extensions: dom, curl, fileinfo, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, gd, ldap, intl, pspell
5555
tools: composer:v2
5656
coverage: none
5757

5858
- name: Setup NPM
59-
uses: actions/setup-node@v4
59+
uses: actions/setup-node@cdca7365b2dadb8aad0a33bc7601856ffabcc48e # v4.3.0
6060
with:
6161
node-version: '16'
6262

@@ -72,7 +72,7 @@ jobs:
7272
- name: Upload screenshots as artifacts
7373
# Upload screenshot if the test suite failed.
7474
if: failure()
75-
uses: actions/upload-artifact@v4
75+
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
7676
with:
7777
name: screenshots
7878
path: tests/Browser/screenshots

.github/workflows/ci.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ jobs:
1616

1717
steps:
1818
- name: Checkout code
19-
uses: actions/checkout@v4
19+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
2020

2121
- name: Setup PHP
22-
uses: shivammathur/setup-php@v2
22+
uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0
2323
with:
2424
php-version: "8.3"
2525
extensions: mbstring
@@ -57,10 +57,10 @@ jobs:
5757

5858
steps:
5959
- name: Checkout code
60-
uses: actions/checkout@v4
60+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
6161

6262
- name: Setup PHP
63-
uses: shivammathur/setup-php@v2
63+
uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0
6464
with:
6565
php-version: "8.3"
6666
extensions: mbstring

.github/workflows/docker_image.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,20 +27,20 @@ jobs:
2727
id-token: write
2828
steps:
2929
- name: Check actor permission
30-
uses: skjnldsv/check-actor-permission@v3
30+
uses: skjnldsv/check-actor-permission@69e92a3c4711150929bca9fcf34448c5bf5526e7 # v3.0
3131
with:
3232
require: admin
3333
- name: Check out the repo
34-
uses: actions/checkout@v4
34+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
3535
- name: Log in to the Container registry
36-
uses: docker/login-action@v3
36+
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
3737
with:
3838
registry: ghcr.io
3939
username: ${{ github.actor }}
4040
password: ${{ secrets.GITHUB_TOKEN }}
4141
- name: Build and push Docker image
4242
id: push
43-
uses: docker/build-push-action@v6
43+
uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 # v6.15.0
4444
with:
4545
context: .
4646
file: ./.ci/docker-images/Dockerfile

.github/workflows/message_rendering.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919

2020
steps:
2121
- name: Checkout code
22-
uses: actions/checkout@v4
22+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
2323

2424
# Run via docker compose because we can't run greenmail in a server here
2525
# (it requires the testing emails to be present when starting but
@@ -29,7 +29,7 @@ jobs:
2929
run: docker compose -f .ci/compose.yaml run test_message_rendering
3030

3131
- name: Upload artifacts
32-
uses: actions/upload-artifact@master
32+
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
3333
if: failure()
3434
with:
3535
name: Logs

.github/workflows/tests.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ jobs:
2121

2222
steps:
2323
- name: Checkout code
24-
uses: actions/checkout@v4
24+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
2525

2626
- name: Setup PHP
27-
uses: shivammathur/setup-php@v2
27+
uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0
2828
with:
2929
php-version: ${{ matrix.php }}
3030
extensions: dom, curl, fileinfo, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, gd, ldap, intl, pspell, enchant
@@ -45,7 +45,7 @@ jobs:
4545
run: .ci/run_tests.sh
4646

4747
- name: Upload artifacts
48-
uses: actions/upload-artifact@master
48+
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
4949
if: failure()
5050
with:
5151
name: Logs
@@ -64,10 +64,10 @@ jobs:
6464

6565
steps:
6666
- name: Checkout code
67-
uses: actions/checkout@v4
67+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
6868

6969
- name: Setup PHP
70-
uses: shivammathur/setup-php@v2
70+
uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0
7171
with:
7272
php-version: ${{ matrix.php }}
7373
extensions: dom, curl, fileinfo, libxml, mbstring, zip, pdo, sqlite, pdo_sqlite, gd, ldap, intl
@@ -78,7 +78,7 @@ jobs:
7878
run: bash -ex .ci/run_tests.sh
7979

8080
- name: Upload artifacts
81-
uses: actions/upload-artifact@master
81+
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
8282
if: failure()
8383
with:
8484
name: Logs

0 commit comments

Comments
 (0)