ci(scorecard): add OpenSSF Scorecard workflow + README badges#16
Merged
Conversation
Adds .github/workflows/scorecard.yml — runs the OpenSSF Scorecard
supply-chain check on push to main, weekly cron, and on
branch_protection_rule changes. Results land in two places:
- GitHub code-scanning (/security/code-scanning) via SARIF upload
- Public Scorecard registry (api.scorecard.dev) via OIDC publish so
the README badge resolves to a live score
All third-party actions are pinned to commit SHAs:
- actions/checkout@v4
- ossf/scorecard-action@v2.4.3
- actions/upload-artifact@v7.0.1
- github/codeql-action/upload-sarif@v4.35.2
README: add the Scorecard badge to the badge row, plus an HTML
comment with the one-time steps to register the project at
bestpractices.dev and append the Best Practices badge once a
PROJECT_ID has been issued (the badge URL is invalid until the
project is registered, so it's documented inline rather than
shipped broken).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sonar githubactions:S8234 flagged 'permissions: read-all' as a vulnerability. Job-level permissions already grant exactly what the scorecard analyzer needs (security-events: write for SARIF upload, id-token: write for OIDC publish, contents: read, actions: read); the top-level grant is only a fallback for any future steps without their own block, so contents:read is the right minimum.
|
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Summary
Test plan
🤖 Generated with Claude Code