ci(cla): auto-record portal signatures + label server-side - #3
Merged
Merged
Conversation
Portal signature issues could never be processed into .cla/signatures.json without a manual owner commit. New cla-sync workflow: on [CLA] Signature issue -> validate identity (issue opener must equal claimed GitHub user, matching the portal's OAuth auto-fill) -> append to signatures.json (idempotent re-sign) -> apply the cla-signature label server-side (contributors cannot create labels) -> open an auto-generated PR for owner approval -> comment + close. cla-check bot comment now tells contributors to wait for the green submit confirmation, so a silently failed submission is noticed immediately. Requires secret OWNER_PAT (contents:write on this repo) — org default workflow token is read-only.
…ion)
Cora review flagged CRITICAL: attacker-controlled outputs (issue body)
interpolated via ${{ }} into github-script source. Read them through
process.env instead. Also: don't close the issue when the PR step
failed, so a failed submission stays open with the failure comment as
the audit trail.
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.
What
.github/workflows/cla-sync.yml: listens for[CLA] Signatureissues from the signing portal (https://codecoradev.github.io/cla/), validates them (issue opener must equal the claimed GitHub user — matches the portal's OAuth auto-fill; CLA type must be individual/corporate), appends the entry to.cla/signatures.json(idempotent on re-sign), applies thecla-signaturelabel server-side, opens an auto-generated PR for owner approval, comments on the issue, and closes it.cla-check.yml: bot comment now instructs contributors to wait for the green submit confirmation before closing the tab.OWNER_PAT(classic PAT,public_reposcope is sufficient for this public repo) — org default workflow permission is read, so ${{ secrets.GITHUB_TOKEN }} cannot push or apply labels.Why
Testing
- **Name:**etc.)