Skip to content

Commit 9f3c83a

Browse files
authored
fix(ci): declare permissions at the top-level (#83)
1 parent 31f418c commit 9f3c83a

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

.github/workflows/scorecard.yml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,20 +16,18 @@ on:
1616
- main
1717
workflow_call:
1818

19-
# Declare default permissions as read only.
20-
permissions: read-all
19+
permissions:
20+
# Needed to upload the results to code-scanning dashboard.
21+
security-events: write
22+
# Needed to publish results and get a badge (see publish_results below).
23+
id-token: write
24+
contents: read
25+
actions: read
2126

2227
jobs:
2328
analysis:
2429
name: Scorecard analysis
2530
runs-on: ubuntu-latest
26-
permissions:
27-
# Needed to upload the results to code-scanning dashboard.
28-
security-events: write
29-
# Needed to publish results and get a badge (see publish_results below).
30-
id-token: write
31-
contents: read
32-
actions: read
3331

3432
steps:
3533
- name: Harden Runner

0 commit comments

Comments
 (0)