Skip to content

ci: OpenSSF Scorecard + Sigstore artifact signing - #24

Merged
JordanNewell merged 2 commits into
mainfrom
feat/scorecard
Nov 27, 2026
Merged

JordanNewell merged 2 commits into
mainfrom
feat/scorecard

Conversation

@JordanNewell

Copy link
Copy Markdown
Collaborator

What

Trust-stack build-out, two commits:

  1. OpenSSF Scorecard workflow + badge (.github/workflows/scorecard.yml, README badge)

    • Weekly cron (23 19 * * 6), on branch-protection-rule changes, and pushes to main
    • permissions: read-all at workflow level, job-level least-privilege (id-token: write for the scorecard publisher)
    • SARIF results published to the public Scorecard viewer, uploaded as an artifact, and ingested into GitHub code scanning
    • Badge lands next to the existing README badges and feeds the future tokenhunt.dev metrics page
  2. cosign signing in release.yml (inserted before the softprops upload step)

    • sigstore/cosign-installer + cosign sign-blob for dist/*.tar.gz and dist/*.whl, with .sig files added to the release files: list
    • || true is deliberate: signing must never fail a release; the next tag retries signing on its own artifacts
    • PyPI Trusted Publishing already produces PEP 740 attestations for the PyPI uploads; this signs the GitHub-release artifacts, which are a separate distribution surface

Pin provenance

All actions pinned to full commit SHAs, resolution date 2026-11-27:

  • actions/checkout@3d3c42e — v4 (existing repo pin, unchanged)
  • ossf/scorecard-action@23f22cd — v2.6.0, latest release (published 2026-11-19)
  • actions/upload-artifact@ea165f8 — v4.6.2, latest v4 tag (v4 chosen to match the repo's conservative major-pinning; current upstream major is v7)
  • github/codeql-action/upload-sarif@74c1aea — v3 (existing repo pin, unchanged)
  • sigstore/cosign-installer@881c63b — v4.1.4, latest release (published 2026-11-24). Note: v4 superseded v3 on 2026-11-24; the current major is pinned rather than the outdated v3 line. cosign sign-blob --yes behavior is unchanged in v4.

Why

OpenSSF Scorecard + Best Practices "Passing" posture for token-hunt: automated scorecard scoring, signed release artifacts, and the badge as public trust signal.

Gates

  • Both workflow files YAML-validated locally
  • ruff check . clean; full pytest suite run locally (801 passed; one pre-existing Windows-local failure in test_watch_detects_new_file, reproduces on clean main, unrelated to this diff — CI green on all 3 OSes)

@JordanNewell
JordanNewell merged commit 63aadb6 into main Nov 27, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant