Skip to content

Commit 6097ee3

Browse files
authored
ci: Constrain CI runner access (#357)
1 parent acface6 commit 6097ee3

5 files changed

Lines changed: 32 additions & 23 deletions

File tree

.github/actions/build-gosop/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ runs:
1616
using: "composite"
1717
steps:
1818
- name: Checkout gopenpgp
19-
uses: actions/checkout@v4
19+
uses: actions/checkout@v6
2020
with:
2121
ref: ${{ inputs.gopenpgp-ref }}
2222
path: gopenpgp
@@ -32,7 +32,7 @@ runs:
3232
with:
3333
go-version: ^1.18
3434
- name: Check out gosop
35-
uses: actions/checkout@v4
35+
uses: actions/checkout@v6
3636
with:
3737
repository: ProtonMail/gosop
3838
ref: ${{ env.GOSOP_BRANCH_REF}}

.github/workflows/android.yml

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,22 @@ on:
66
pull_request:
77
branches: [ main, v3 ]
88

9+
permissions: {}
10+
911
jobs:
1012
build:
1113
name: Build library for Android with gomobile
1214
runs-on: ubuntu-latest
1315

1416
steps:
15-
- name: Set up JDK 1.8
16-
uses: actions/setup-java@v1
17+
- name: Set up JDK 8
18+
uses: actions/setup-java@v5
1719
with:
18-
java-version: 1.8
20+
distribution: 'zulu'
21+
java-version: 8
1922

2023
- name: Set up Go 1.x
21-
uses: actions/setup-go@v5
24+
uses: actions/setup-go@v6
2225
with:
2326
go-version: ^1.16
2427
id: go
@@ -30,7 +33,7 @@ jobs:
3033
link-to-sdk: true
3134

3235
- name: Checkout
33-
uses: actions/checkout@v4
36+
uses: actions/checkout@v6
3437

3538
- name: Build
3639
run: |
@@ -41,7 +44,7 @@ jobs:
4144
find dist
4245
4346
- name: Upload Android artifacts
44-
uses: actions/upload-artifact@v4
47+
uses: actions/upload-artifact@v7
4548
with:
4649
name: Android build
4750
path: dist/android

.github/workflows/go.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,18 @@ on:
66
pull_request:
77
branches: [ main, Proton ]
88

9+
permissions: {}
10+
911
jobs:
1012
test:
1113
name: Test with latest golang
1214
runs-on: ubuntu-latest
1315
steps:
1416
- name: Check out repo
15-
uses: actions/checkout@v4
17+
uses: actions/checkout@v6
1618

1719
- name: Set up latest golang
18-
uses: actions/setup-go@v5
20+
uses: actions/setup-go@v6
1921
with:
2022
go-version: '^1.18'
2123

@@ -26,10 +28,10 @@ jobs:
2628
name: Lint
2729
runs-on: ubuntu-latest
2830
steps:
29-
- uses: actions/setup-go@v5
31+
- uses: actions/setup-go@v6
3032
with:
3133
go-version: '1.23'
32-
- uses: actions/checkout@v4
34+
- uses: actions/checkout@v6
3335
- name: golangci-lint
3436
uses: golangci/golangci-lint-action@v3
3537
with:

.github/workflows/ios.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ on:
66
pull_request:
77
branches: [ main, v3 ]
88

9+
permissions: {}
10+
911
jobs:
1012
build:
1113
name: Build library for iOS with gomobile
@@ -19,13 +21,13 @@ jobs:
1921
id: xcode
2022

2123
- name: Set up Go 1.x
22-
uses: actions/setup-go@v2
24+
uses: actions/setup-go@v6
2325
with:
2426
go-version: ^1.16
2527
id: go
2628

2729
- name: Checkout
28-
uses: actions/checkout@v4
30+
uses: actions/checkout@v6
2931

3032
- name: Build
3133
env:
@@ -35,7 +37,7 @@ jobs:
3537
find dist
3638
3739
- name: Upload xcframework
38-
uses: actions/upload-artifact@v4
40+
uses: actions/upload-artifact@v7
3941
with:
4042
name: gopenpgp.xcframework
4143
path: dist/apple/gopenpgp.xcframework

.github/workflows/sop-test-suite.yml

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,23 @@ on:
44
pull_request:
55
branches: [ main, v3 ]
66

7+
permissions: {}
8+
79
jobs:
810

911
build-gosop:
1012
name: Build gosop from branch
1113
runs-on: ubuntu-latest
1214
steps:
1315
- name: Checkout
14-
uses: actions/checkout@v4
16+
uses: actions/checkout@v6
1517
- name: Build gosop from branch
1618
uses: ./.github/actions/build-gosop
1719
with:
1820
binary-location: ./gosop-${{ github.sha }}
1921
# Upload as artifact
2022
- name: Upload gosop artifact
21-
uses: actions/upload-artifact@v4
23+
uses: actions/upload-artifact@v7
2224
with:
2325
name: gosop-${{ github.sha }}
2426
path: ./gosop-${{ github.sha }}
@@ -28,15 +30,15 @@ jobs:
2830
runs-on: ubuntu-latest
2931
steps:
3032
- name: Checkout
31-
uses: actions/checkout@v4
33+
uses: actions/checkout@v6
3234
- name: Build gosop from branch
3335
uses: ./.github/actions/build-gosop
3436
with:
3537
gopenpgp-ref: ${{ github.base_ref }}
3638
binary-location: ./gosop-target
3739
# Upload as artifact
3840
- name: Upload gosop-target artifact
39-
uses: actions/upload-artifact@v4
41+
uses: actions/upload-artifact@v7
4042
with:
4143
name: gosop-target
4244
path: ./gosop-target
@@ -55,7 +57,7 @@ jobs:
5557
- build-gosop-target
5658
steps:
5759
- name: Checkout
58-
uses: actions/checkout@v4
60+
uses: actions/checkout@v6
5961
# Fetch gosop from target
6062
- name: Download gosop-target
6163
uses: actions/download-artifact@v4
@@ -94,12 +96,12 @@ jobs:
9496
RESULTS_HTML: .github/test-suite/test-suite-results.html
9597
# Upload results
9698
- name: Upload test results json artifact
97-
uses: actions/upload-artifact@v4
99+
uses: actions/upload-artifact@v7
98100
with:
99101
name: test-suite-results.json
100102
path: .github/test-suite/test-suite-results.json
101103
- name: Upload test results html artifact
102-
uses: actions/upload-artifact@v4
104+
uses: actions/upload-artifact@v7
103105
with:
104106
name: test-suite-results.html
105107
path: .github/test-suite/test-suite-results.html
@@ -110,7 +112,7 @@ jobs:
110112
needs: test-suite
111113
steps:
112114
- name: Checkout
113-
uses: actions/checkout@v4
115+
uses: actions/checkout@v6
114116
- name: Download test results json artifact
115117
id: download-test-results
116118
uses: actions/download-artifact@v4

0 commit comments

Comments
 (0)