-
Notifications
You must be signed in to change notification settings - Fork 0
75 lines (66 loc) · 2.62 KB
/
Copy pathsecurity.yml
File metadata and controls
75 lines (66 loc) · 2.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
name: security
on:
pull_request:
branches: [main]
push:
branches: [main]
schedule:
# Weekly, so an advisory published after the last push is still seen.
- cron: '17 4 * * 1'
# Same reason as `ci`: an advisory worth re-checking now, or a scheduled run
# that never started, should not require a commit to ask about.
workflow_dispatch:
permissions:
contents: read
concurrency:
group: security-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false
jobs:
codeql:
name: codeql
permissions:
actions: read # CodeQL reads the workflow definitions it analyses
contents: read
security-events: write # CodeQL publishes its findings to code scanning
uses: NDDev-OpenNetwork/ci-workflows/.github/workflows/public-codeql.yml@e90a2c7c6c25cd1fb9ac1c68adbc7535f8b17e1e
with:
languages: '["rust", "actions"]'
queries: security-and-quality
dependency-review:
name: dependency-review
if: github.event_name == 'pull_request'
permissions:
contents: read
pull-requests: write # writes the review it produces
uses: NDDev-OpenNetwork/ci-workflows/.github/workflows/public-dependency-review.yml@e90a2c7c6c25cd1fb9ac1c68adbc7535f8b17e1e
with:
fail_on_severity: moderate
scorecard:
name: scorecard
if: github.event_name != 'pull_request'
permissions:
# A called workflow cannot request more than its caller granted, and the
# run fails at startup rather than mid-job when it tries. Scorecard reads
# workflow definitions, so actions: read is part of the set, not an extra.
actions: read # Scorecard reads workflow definitions
contents: read
id-token: write # mints the OIDC token Scorecard's publication is signed with
security-events: write # Scorecard publishes its findings to code scanning
uses: NDDev-OpenNetwork/ci-workflows/.github/workflows/public-scorecard.yml@e90a2c7c6c25cd1fb9ac1c68adbc7535f8b17e1e
osv:
name: osv
permissions:
contents: read
uses: NDDev-OpenNetwork/ci-workflows/.github/workflows/osv-scan.yml@e90a2c7c6c25cd1fb9ac1c68adbc7535f8b17e1e
zizmor:
name: zizmor
permissions:
actions: read # the SARIF upload reads this run to attach its results
contents: read
security-events: write # zizmor publishes its findings to code scanning
uses: NDDev-OpenNetwork/ci-workflows/.github/workflows/zizmor-sarif.yml@e90a2c7c6c25cd1fb9ac1c68adbc7535f8b17e1e
secret-scan:
name: secret-scan
permissions:
contents: read
uses: NDDev-OpenNetwork/ci-workflows/.github/workflows/secret-scan.yml@e90a2c7c6c25cd1fb9ac1c68adbc7535f8b17e1e