Check: Scorecard #52
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "Check: Scorecard" | |
on: | |
## Manual dispatch | |
workflow_dispatch: {} | |
## Sub-workflow call | |
workflow_call: {} | |
## Scheduled checks | |
schedule: | |
- cron: '20 7 * * 2' | |
# Declare default permissions as read only. | |
permissions: | |
contents: read | |
jobs: | |
check-scorecard: | |
name: "Checks: Scorecard" | |
runs-on: ubuntu-latest | |
permissions: | |
# Needed to upload the results to code-scanning dashboard. | |
security-events: write | |
# Needed to publish results and get a badge (see publish_results below). | |
id-token: write | |
contents: read | |
actions: read | |
steps: | |
- name: "Setup: Harden Runner" | |
uses: step-security/harden-runner@f086349bfa2bd1361f7909c78558e816508cdc10 # v2.8.0 | |
with: | |
disable-sudo: true | |
egress-policy: block | |
allowed-endpoints: > | |
api.github.com:443 | |
api.osv.dev:443 | |
api.securityscorecards.dev:443 | |
fulcio.sigstore.dev:443 | |
github.com:443 | |
oss-fuzz-build-logs.storage.googleapis.com:443 | |
rekor.sigstore.dev:443 | |
tuf-repo-cdn.sigstore.dev:443 | |
www.bestpractices.dev:443 | |
- name: "Setup: Checkout" | |
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 | |
with: | |
persist-credentials: false | |
- name: "Checks: Scorecard" | |
uses: ossf/scorecard-action@62b2cac7ed8198b15735ed49ab1e5cf35480ba46 # v2.4.0 | |
with: | |
results_file: results.sarif | |
results_format: sarif | |
publish_results: true | |
- name: "Artifacts: SARIF Report" | |
uses: actions/upload-artifact@50769540e7f4bd5e21e526ee35c689e35e0d6874 # v4.4.0 | |
with: | |
name: "Scorecard SARIF" | |
path: results.sarif | |
retention-days: 5 | |
- name: "Reporting: Upload SARIF" | |
uses: github/codeql-action/upload-sarif@4355270be187e1b672a7a1c7c7bae5afdc1ab94a # v3.24.10 | |
with: | |
sarif_file: results.sarif |