Scorecards supply-chain security #1102
This file contains hidden or 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: Scorecards supply-chain security | |
| on: | |
| # For Branch-Protection check. Only the default branch is supported. See | |
| # https://github.com/ossf/scorecard/blob/main/docs/checks.md#branch-protection | |
| branch_protection_rule: | |
| schedule: | |
| # Run security checks every day at 2 AM UTC | |
| - cron: "0 2 * * *" | |
| workflow_dispatch: | |
| permissions: {} # No permissions by default on workflow level | |
| jobs: | |
| analysis: | |
| name: Scorecards analysis | |
| 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 | |
| id-token: write | |
| steps: | |
| - name: Harden the runner (audit all outbound calls) | |
| uses: step-security/harden-runner@b09bb98e06d4d774595224525879c09bc6e98c40 # v2.20.1 | |
| with: | |
| egress-policy: audit | |
| - name: Checkout code | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| with: | |
| persist-credentials: false | |
| - name: Run analysis | |
| uses: ossf/scorecard-action@2d1146689b8cda280b9bc96326124645441f03bc # v2.4.4 | |
| with: | |
| results_file: results.sarif | |
| results_format: sarif | |
| publish_results: true | |
| # Upload the results to GitHub's code scanning dashboard | |
| - name: Upload to code-scanning | |
| uses: github/codeql-action/upload-sarif@5595ccaf912efad79be6eef63a5619ff05969be3 # v4.37.6 | |
| with: | |
| sarif_file: results.sarif |