Skip to content

fix(ci): harden publish workflows with provenance and Sigstore verification#25

Merged
henrypalacios merged 1 commit into
mainfrom
feat/publish-workflows-hardening
May 4, 2026
Merged

fix(ci): harden publish workflows with provenance and Sigstore verification#25
henrypalacios merged 1 commit into
mainfrom
feat/publish-workflows-hardening

Conversation

@henrypalacios
Copy link
Copy Markdown
Collaborator

@henrypalacios henrypalacios commented May 4, 2026

Summary

Port the hardened publish workflow pattern from quickswap-default-token-list/.github/workflows/publish.yaml to both SDK publish workflows. Reviewed via judgment-day dual blind review — APPROVED on round 1.

Structural changes

  • Separate bump-and-tag job before publish-npm with atomic git push --atomic of branch + tag and a 3-attempt retry on non-fast-forward.
  • Tag pre-check via git ls-remote fails fast on collision.
  • publish-npm checks out the exact SHA produced by bump-and-tag (workflow_dispatch path) or the tag ref (push:tags recovery path).
  • Concurrency groups (publish-sdk, publish-protocol-core) serialize per-package dispatches.

Operational improvements

  • Tag commit validation on the release path (ancestry + subject + author).
  • Sigstore signature verification post-publish via npm audit signatures --include-attestations with 10-attempt retry.
  • SLSA predicate type assertion in registry metadata.
  • --ignore-scripts on all pnpm and npm install invocations.
  • Idempotent GitHub Release creation (gh release view guard, heredoc-based notes).
  • Robust check_version with explicit E404 detection and retry.
  • npm pinned to 11.13.0 in verify-publish (--include-attestations requires >= 11.12.0).
  • Polling-based registry propagation (replaces fixed sleep 30).
  • Real dry-run path with npm publish --dry-run preview.

Test plan

  • Manual workflow_dispatch with dry_run: true for publish-sdk.yaml
  • Manual workflow_dispatch with dry_run: true for publish-protocol-core.yaml
  • Real publish of @quickswap-defi/protocol-core patch bump via workflow_dispatch after merge
  • Confirm Sigstore verification passes (registry propagation up to ~2.5 min)
  • Confirm GitHub Release is created with correct title and notes
  • Confirm tag is on main and signed commit author matches the release bot

Reference

  • Source: quickswap-default-token-list/.github/workflows/publish.yaml
  • Linted with actionlint — no errors

@henrypalacios henrypalacios force-pushed the feat/publish-workflows-hardening branch from 294b4e9 to 6b96647 Compare May 4, 2026 15:27
Replace publish-sdk and publish-protocol-core with the workflow pattern
already in use at quickswap-default-token-list/.github/workflows/publish.yaml.

Structural changes:
- Separate bump-and-tag job before publish-npm with atomic git push
  (--atomic) and 3-attempt retry on non-fast-forward
- Tag pre-check via git ls-remote
- publish-npm checks out the exact SHA produced by bump-and-tag
- Concurrency groups (publish-sdk, publish-protocol-core) per package

Operational improvements:
- Tag commit validation on the release path (ancestry + subject + author)
- Sigstore signature verification post-publish via npm audit signatures
  --include-attestations with retry
- SLSA predicate type assertion in registry metadata
- --ignore-scripts on all pnpm and npm install invocations
- Idempotent GitHub Release creation (gh release view guard, heredoc)
- Robust check_version with retry and E404 detection
- npm pinned to 11.13.0 in verify-publish (--include-attestations
  requires >= 11.12.0)
- Polling-based registry propagation
- Real dry-run preview path
@henrypalacios henrypalacios force-pushed the feat/publish-workflows-hardening branch from 6b96647 to 7f0376a Compare May 4, 2026 15:53
@henrypalacios henrypalacios merged commit 4a3fba8 into main May 4, 2026
2 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