Skip to content

Commit 0adc659

Browse files
authored
Merge pull request #45 from 1Password/chore/GHA-151739-stepsecurity-remediation
Apply GitHub Actions security best practices
2 parents cde24c0 + 24c710e commit 0adc659

3 files changed

Lines changed: 60 additions & 4 deletions

File tree

.github/dependabot.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: github-actions
4+
directory: /
5+
schedule:
6+
interval: weekly
7+
cooldown:
8+
default-days: 7
9+
10+
- package-ecosystem: npm
11+
directory: /dist
12+
schedule:
13+
interval: weekly
14+
cooldown:
15+
default-days: 7
16+
semver-major-days: 30
17+
semver-minor-days: 14
18+
semver-patch-days: 5
19+
20+
- package-ecosystem: npm
21+
directory: /
22+
schedule:
23+
interval: weekly
24+
cooldown:
25+
default-days: 7
26+
semver-major-days: 30
27+
semver-minor-days: 14
28+
semver-patch-days: 5

.github/workflows/pr-check-signed-commits.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
name: Check signed commits in PR
22
on: pull_request_target
33

4+
permissions:
5+
contents: read
6+
47
jobs:
58
build:
69
name: Check signed commits in PR
@@ -9,5 +12,10 @@ jobs:
912
pull-requests: write
1013
runs-on: ubuntu-latest
1114
steps:
15+
- name: Harden the runner (Audit all outbound calls)
16+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
17+
with:
18+
egress-policy: audit
19+
1220
- name: Check signed commits in PR
1321
uses: 1Password/check-signed-commits-action@v1

.github/workflows/test.yml

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,12 @@ jobs:
99
os: [ubuntu-latest, macos-latest, windows-latest]
1010
runs-on: ${{ matrix.os }}
1111
steps:
12-
- uses: actions/checkout@v6
12+
- name: Harden the runner (Audit all outbound calls)
13+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
14+
with:
15+
egress-policy: audit
16+
17+
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
1318
- name: Install 1Password CLI
1419
uses: ./ # 1password/install-cli-action@<version>
1520
- name: Check CLI version
@@ -21,7 +26,12 @@ jobs:
2126
os: [ubuntu-latest, macos-latest, windows-latest]
2227
runs-on: ${{ matrix.os }}
2328
steps:
24-
- uses: actions/checkout@v6
29+
- name: Harden the runner (Audit all outbound calls)
30+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
31+
with:
32+
egress-policy: audit
33+
34+
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
2535
- name: Install 1Password CLI
2636
uses: ./ # 1password/install-cli-action@<version>
2737
with:
@@ -35,7 +45,12 @@ jobs:
3545
os: [ubuntu-latest, macos-latest, windows-latest]
3646
runs-on: ${{ matrix.os }}
3747
steps:
38-
- uses: actions/checkout@v6
48+
- name: Harden the runner (Audit all outbound calls)
49+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
50+
with:
51+
egress-policy: audit
52+
53+
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
3954
- name: Install 1Password CLI
4055
uses: ./ # 1password/install-cli-action@<version>
4156
with:
@@ -49,7 +64,12 @@ jobs:
4964
os: [ubuntu-latest, macos-latest, windows-latest]
5065
runs-on: ${{ matrix.os }}
5166
steps:
52-
- uses: actions/checkout@v6
67+
- name: Harden the runner (Audit all outbound calls)
68+
uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0
69+
with:
70+
egress-policy: audit
71+
72+
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
5373
- name: Install 1Password CLI
5474
uses: ./ # 1password/install-cli-action@<version>
5575
with:

0 commit comments

Comments
 (0)