99 - cron : ' 0 6 * * 1' # Weekly on Monday
1010 workflow_dispatch :
1111
12+ # Estate guardrail: cancel superseded runs so re-pushes / rebased PR
13+ # updates do not pile up queued runs against the shared account-wide
14+ # Actions concurrency pool. Applied only to read-only check workflows
15+ # (no publish/mutation), so cancelling a superseded run is always safe.
16+ concurrency :
17+ group : ${{ github.workflow }}-${{ github.ref }}
18+ cancel-in-progress : true
19+
1220permissions :
1321 contents : read
1422
@@ -19,28 +27,42 @@ jobs:
1927 security-events : write
2028 id-token : write # For OIDC
2129 steps :
22- - uses : actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
30+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2331 with :
2432 persist-credentials : false
2533
2634 - name : Run Scorecard
27- uses : ossf/scorecard-action@62b2cac7ed8198b15735ed49ab1e5cf35480ba46 # v2.4.0
35+ uses : ossf/scorecard-action@4eaacf0543bb3f2c246792bd56e8cdeffafb205a # v2.4.3
2836 with :
2937 results_file : results.sarif
3038 results_format : sarif
3139 publish_results : true
3240
3341 - name : Upload SARIF
34- uses : github/codeql-action/upload-sarif@6624720a57d4c312633c7b953db2f2da5bcb4c3a # v3
42+ uses : github/codeql-action/upload-sarif@c6f931105cb2c34c8f901cc885ba1e2e259cf745 # v4
3543 with :
3644 sarif_file : results.sarif
3745
38- # Check specific high-priority items (separate job so run: steps
39- # do not contaminate the scorecard job that publishes results)
46+ - name : Check minimum score
47+ run : |
48+ # Parse score from results
49+ SCORE=$(jq -r '.runs[0].tool.driver.properties.score // 0' results.sarif 2>/dev/null || echo "0")
50+
51+ echo "OpenSSF Scorecard Score: $SCORE"
52+
53+ # Minimum acceptable score (0-10 scale)
54+ MIN_SCORE=5
55+
56+ if [ "$(echo "$SCORE < $MIN_SCORE" | bc -l)" = "1" ]; then
57+ echo "::error::Scorecard score $SCORE is below minimum $MIN_SCORE"
58+ exit 1
59+ fi
60+
61+ # Check specific high-priority items
4062 check-critical :
4163 runs-on : ubuntu-latest
4264 steps :
43- - uses : actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
65+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
4466
4567 - name : Check SECURITY.md exists
4668 run : |
0 commit comments