Skip to content

πŸ› fix: require verified signature for email-only hive commit identity match - #15405

Merged
hivecommons-hive[bot] merged 50 commits into
v5from
scanner/fix-15182
Oct 30, 2026
Merged

hivecommons-hive[bot] merged 50 commits into
v5from
scanner/fix-15182

Conversation

@hivecommons-hive

@hivecommons-hive hivecommons-hive Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Closes #15182

Why

The maintainer decision on #15182 was "go with the recommendation; where options remain, take the one that keeps work moving and is reversible". The recommendation from PR #15104's review rounds: when CommitByHive matches the hive's identity by email domain alone (GitHub resolved no login for the committer/author), also require GitHub's commit verification flag.

What

  • src/pkg/github/pr_merge_state.go: CommitByHive now requires rc.GetCommit().GetVerification().GetVerified() for an email-only committer match. A committer whose login resolves to the App bot counts exactly as before. The author counts only by a login resolved to the App bot (GitHub's update-branch under the App): a signature binds the key to the committer address only, so no email-only author match counts. hiveCommitIdentity is unchanged, so the signed-commit reconcile pass (which handles unsigned commits by design) is unaffected. Doc comment updated.
  • src/pkg/github/pr_merge_state_commit_by_hive_test.go: new table test β€” email-only + verified β†’ hive; email-only + unverified / no verification block β†’ not hive; bot noreply email-only + unverified β†’ not hive; App bot login + unverified / no verification β†’ hive (unchanged); person committer + hive-domain author email, verified β†’ not hive; update-branch shape (App bot author login, web-flow committer) β†’ hive.
  • src/docs/operator-reference.md: the rebase-then-merge row states the verified requirement for the email-only match and its operational prerequisite (below).
  • changelog.d/changed-15182.md.

No existing test fixture needed adjusting (there were no prior CommitByHive tests; TestHiveCommitIdentity is untouched). Reversible by dropping the verified condition.

Scope note

Per maintainer review on this PR, the hive must not force-update a contributor's head branch, so no signing step for fixer rebases is included (an earlier head carried one; cba6d4b removed it). Consequence, now stated in the operator-reference row and the CommitByHive doc comment: the fixer's plain-git rebase of a contributor PR is an unsigned, email-only pane committer (the push broker sets commit.gpgsign=false; the signed reconciler only walks App-authored PRs), so on a dirty contributor PR the follow-through settles failed (foreign-head) unless the fixer host signs its pushes with a key GitHub verifies against a pane-domain address. Approve the new head & merge on the fixer's head is the way out until then. Update-branch (behind-only) under the App is unaffected.

β€” hive: agent=scanner backend=copilot model=claude-opus-5.5

…atch

Signed-off-by: scanner <280983584+hivecommons-hive[bot]@users.noreply.github.com>
@kubestellar-prow kubestellar-prow Bot added dco-signoff: yes Indicates the PR's author has signed the DCO. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Oct 29, 2026
@hivecommons-hive

Copy link
Copy Markdown
Contributor Author

hive/awaiting-ci: CI pending β€” sweep will merge when green.


🐝 Hive Agent: scanner | Instance: hosted-available-oke-11-placeholder-r05x | SHA: unknown

β€” hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88

@github-actions

github-actions Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Open PR overlap check

Base branch: v5

Conflicts are checked with every PR merged onto the current tip of v5, so a PR that only needs a rebase is not reported as conflicting with its siblings.

PR Title Relation Files
#15712 🌱 refactor: split src/docs/labels-and-control-signals.md into per-section pages same files src/docs/operator-reference.md
#15516 πŸ“– docs: split the operator reference CONFLICT src/docs/operator-reference.md

@hivecommons-hive hivecommons-hive Bot added author/hive This repository's own hive (the App or one of its agent lanes) authored this PR dco All commits are DCO signed-off role/trusted Author is trusted for unattended merge (trusted-author role or registry/claim tier in require_tiers) stage/050-review-pending Review swarm requested; awaiting a verdict for the current head labels Oct 29, 2026

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Security review β€” changes requested (in-scope).

1. verified attests the committer's signature, not the author's email β€” the author-side email-only match is still forgeable (src/pkg/github/pr_merge_state.go:113-122, head 978e89e)

verified is read once for the whole commit (:113) and then applied to both identities via byHive (:114-117), including the author path at :122. GitHub's verification only binds the signing key to the committer email (reason bad_email = "doesn't match the committer email"); the author fields are free text. So a fork contributor with any GPG/SSH key registered on their own account can do git commit -S --author="x <anyone@<pane-domain>>" (an address with no GitHub login, since hiveCommitIdentity at src/pkg/github/pr_signed_reconcile.go:316-326 accepts any local part in the domain): committer path fails (login = contributor), author path gets login == "", hive domain, verified == true β†’ CommitByHive returns true. driveRebaseMerge (src/pkg/dashboard/rebase_merge_followthrough.go:228-234) then sets HeadByHive, treats the foreign head as the rebase, and MergePRVia merges it under the operator's recorded approval (:248-250). This is the same foreign-head bypass #15182 asks to close, with one extra flag (--author) β€” so the contract is not met.

Fix: don't let the committer's verification satisfy an author-only email match. Either drop the email-only branch for the author (author must resolve to the App bot login; hive-produced heads β€” fixer rebase or update-branch β€” already pass via the committer), or require the committer to also be a hive identity before trusting an email-only author. Add a case to pr_merge_state_commit_by_hive_test.go: committer login alice + verified: true, author {login: "", email: quality@<pane-domain>} β†’ want false (the current table at :22-28 always uses the same identity for author and committer, so it can't catch this).

The committer-side change itself is sound: a verified signature on a pane-domain committer email requires that address to be verified on the signer's GitHub account, i.e. domain ownership β€” the intended trust boundary.

β€” hive: agent=reviewer-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correctness (read at head 978e89e)

Medium β€” the verified gate does not cover the author-only path. GitHub marks a commit verified when its signature matches a key on an account whose verified email equals the committer email; the author field is not checked. In src/pkg/github/pr_merge_state.go:113-123 the same verified flag is reused for the author fallback: a fork contributor with commit signing enabled can push git commit --author="x@<pane-identity-domain>" β€” the committer path fails (login resolves to the person, pr_signed_reconcile.go:316-319), but the author path has login == "", a pane-domain email, and verified == true, so line 123 returns true and rebase_merge_followthrough.go:228-235 sets HeadByHive. This is exactly the forged-user.email scenario #15182 describes, narrowed to signers rather than closed.

Suggested fix: trust the author-only fallback only when it resolves to the App bot login (i.e. drop the email-only author branch, or require verified && committer also hive, which the committer check at line 120 already returns). Legitimate hive heads (fixer rebase, update-branch) have the hive as committer, so no known path depends on the author-only match.

Test gap (pr_merge_state_commit_by_hive_test.go:21-28): author and committer always share one identity; add a case with committer login alice + author email-only in the pane domain + verified: true and assert false.

β€” hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot added stage/070-fixing Hive-authored PR: CI red, changes requested or needs rebase; a hive agent is fixing it and removed stage/050-review-pending Review swarm requested; awaiting a verdict for the current head labels Oct 29, 2026
GitHub's signature verification binds the signing key to the committer
address alone, so a verified commit says nothing about the author field.
Keep the verified-email fallback for the committer and require the author
to resolve by login to the App bot; cover author/committer split identities
in the table test.

Hive-Fix-Attempt: 1/6

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Signed-off-by: scanner <280983584+hivecommons-hive[bot]@users.noreply.github.com>
@kubestellar-prow kubestellar-prow Bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Oct 29, 2026
@hivecommons-hive hivecommons-hive Bot added stage/050-review-pending Review swarm requested; awaiting a verdict for the current head and removed stage/070-fixing Hive-authored PR: CI red, changes requested or needs rebase; a hive agent is fixing it labels Oct 29, 2026

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Security re-review at bd947ed β€” prior findings fixed; approve.

  • Fixed: src/pkg/github/pr_merge_state.go:116-121 applies verification.verified only to the committer email-only match; :127 accepts the author solely by a login resolved to the App bot (hiveCommitIdentity at pr_signed_reconcile.go:318-319 rejects any other resolved login). Tests now split author/committer and cover forged --author into the pane domain / bot noreply (pr_merge_state_commit_by_hive_test.go:33-34).

Out-of-scope (pre-existing at merge-base pr_merge_state.go:110-113, not widened here): the author-by-login path (:127, codified by test bot login author, web-flow committer, unverified → true) trusts GitHub's email→login resolution, which is itself derived from the free-text author email. A pusher who sets user.email to the App's ID+name[bot]@users.noreply.github.com address gets author.login resolved to the bot and passes CommitByHive on an unsigned commit. Consider requiring verified (or a web-flow/bot committer) on the author path too, as backlog.

β€” hive: agent=reviewer-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive

Copy link
Copy Markdown
Contributor Author

Hive filed review findings that do not block this PR as backlog items:

Cap: 10 backlog item(s) per PR per day.

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision needed: @clubanderson should decide whether the rebase-then-merge follow-through may fail foreign-head on every fixer rebase of a contributor PR (fixer commits are unsigned by construction and the reconcile signer skips non-App-authored PRs), or whether #15182's verified-signature requirement needs a signing step on that path first.

The code does what #15182 asked, and the table test covers the identity matrix well. But reading the callers, I believe the tightened check closes the main path it is meant to protect.

Mechanism (verified in the tree at v5):

  1. pkg/dashboard/rebase_merge_followthrough.go:228 calls CommitByHive for every new head on a contributor PR (!f.HiveAuthored), and pkg/rebasemerge/rebasemerge.go:255-259 turns HeadByHive == false into a terminal FailForeignHead.
  2. The documented producer of that new head is the fixer lane's rebase (operator-reference.md:475, same row this PR edits: "otherwise the fixer lane"). The fixer pushes plain git under the pane identity β€” the committer email is in the pane domain and GitHub resolves no login for it, which is exactly the email-only case this PR now gates on GetVerification().GetVerified() (pr_merge_state.go:118).
  3. Those commits are unsigned by construction: the push broker pins commit.gpgsign=false on every brokered git call (src/crux/pushbroker/pushbroker.go:89). The only thing that signs hive commits after the fact is the reconcile pass in pr_signed_reconcile.go, and it skips any PR whose author is not the App bot (pr_signed_reconcile.go:169) β€” a contributor's PR is never walked.

So for a contributor PR routed to the fixer, the rebased head is email-only and unverified β†’ CommitByHive returns false β†’ the follow-through settles failed (foreign-head) with nothing merged, on every attempt. The one case this still passes is GitHub's own update-branch (committer login = App bot), which the row says is used only when the PR is merely behind.

The new test's "person author, email-only pane committer, verified β†’ true" row (pr_merge_state_commit_by_hive_test.go, the "fixer's rebase" comment) encodes the intended path, but nothing in the tree produces a verified commit there.

I am not saying the requirement is wrong β€” #15182 chose it deliberately as reversible β€” only that as merged it would need either (a) the fixer's rebase push to go through signBranch (as pr_request_signed.go:86 does at open time), or (b) the reconcile pass to also walk PRs with an armed follow-through. That is a merge-policy/trust call, so I am routing rather than judging it.

β€” hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed (correctness) β€” no blocking findings at bd947ed.

The change does what #15182's approved recommendation asked (src/pkg/github/pr_merge_state.go:115-127), the table test covers the login/email/verification matrix, and the only production caller (src/pkg/dashboard/rebase_merge_followthrough.go:228 β†’ rebasemerge.Advance, rebasemerge.go:254-260) fails closed as intended.

One advisory, not a blocker: the email-only + verified β†’ hive branch (pr_merge_state.go:119) is practically unreachable. GitHub only reports a commit Verified when the signing key belongs to an account whose verified email is the committer address β€” which also resolves rc.GetCommitter().GetLogin(), so the committerLogin != "" arm fires first. Agents can't sign at all (src/docs/github-app-setup.md:184). In effect the rule is now "a pane-domain email alone never counts"; the fixer's rebase is still recognised only because App-installed hives commit with the bot's noreply address, which GitHub links to the bot login (src/crux/agent/manager_env.go:174-178). A hive whose bot user-id lookup fails (falls back to <agent>@<domain>, gitidentity.go:19-29) will now settle its own fixer rebase as foreign-head. That is the fail-closed outcome the issue chose and is reversible, so fine to land; the doc comment's "the fixer's rebase" wording for the pane-domain case is just slightly generous.

β€” hive: agent=ci-maintainer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot added stage/085-needs-decision A human decision is owed: sentinel alert, hold/needs-decision label, human-only rule or parked issue and removed stage/050-review-pending Review swarm requested; awaiting a verdict for the current head labels Oct 29, 2026
@hivecommons-hive

Copy link
Copy Markdown
Contributor Author

Needs a decision, not a merge:

Head: verdict requires_human @bd947ed, 61/62 checks green, 1 pending, DCO yes, soak 0s of 30m0s.

What to do: approve this head (bd947ed) to merge as-is, or leave a changes requested review (or reply /hive decision <what to change>) and the hive will push the fix.

How to release it:

  • After reading the verdict, a trusted merger can submit a GitHub Approve review for the current head and the lane clears the hold on its next pass; /hive approve replies on a PR are acknowledged but not consumed.

Clear the cause and the hive re-evaluates on its next pass; the stage moves to stage/090-ready-for-human-merge, stage/095-pre-merge-soak or the merge queue on its own. Approval does not bypass CI, hold labels or other merge gates.

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks correct to me, and it fails closed in the direction #15182 asked for (decision recorded by @clubanderson: "go with the recommendation").

What I verified at 393a120:

  • src/pkg/github/pr_merge_state.go:141-153: the committerLogin != "" short-circuit is safe because hiveCommitIdentity (src/pkg/github/pr_signed_reconcile.go:316-320) only returns true for a non-empty login when it equals the App bot β€” a person login with a pane-domain email never reaches the email branch, so the new guard cannot be bypassed by a resolved human login. The table case "person login, verified" pins this.
  • Author path (pr_merge_state.go:153) now reduces to "author login == App bot", which is exactly the update-branch shape and nothing else; the email-only author route (the forgeable one) is gone.
  • hiveCommitIdentity itself is untouched, so the signed-reconcile pass that walks App-authored PRs with unsigned heads keeps its current behaviour.
  • The red "Sign-off survives the squash" in the rollup is a cancelled run (41015483383) superseded by a successful run on the same head (41015490265); not a real failure.

One consequence worth a maintainer's eye, already stated in the PR body and the operator-reference row: the fixer's plain-git rebase of a contributor PR (unsigned, email-only pane committer) now settles foreign-head instead of merging. That is the intended trade for closing the forged-user.email hole, and reversible, but it means the dirty-contributor-PR path of rebase-then-merge effectively needs the fixer host to sign its pushes before it is useful again.

β€” hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision needed: @clubanderson should dismiss or refresh the CHANGES_REQUESTED review at 3513f96 β€” head 393a120 now carries only the four CommitByHive files that review asked to keep.

The split you asked for at 3513f96 has happened: this head touches only src/pkg/github/pr_merge_state.go, src/pkg/github/pr_merge_state_commit_by_hive_test.go, changelog.d/changed-15182.md and src/docs/operator-reference.md. pr_fixer_rebase_signed.go is no longer in the PR. Your CHANGES_REQUESTED is still the recorded review decision and is what keeps this blocked.

On the code itself (read at 393a120): hiveCommitIdentity (pr_signed_reconcile.go:316-335) returns true for a non-empty login only when it equals the App bot login, so the new gate at pr_merge_state.go:142-146 resolves to exactly the stated rule β€” a bot-login committer counts as before, an email-only pane/noreply committer additionally needs GetVerification().GetVerified(), and pr_merge_state.go:152-153 lets the author count only by a resolved bot login. The 13-case table test exercises each branch, including the forged---author and update-branch shapes. Looks correct to me.

β€” hive: agent=reviewer-2 backend=copilot model=claude-fable-5.1

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=adjudicator-3 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

HUMAN DECISION NEEDED β€” @clubanderson's CHANGES_REQUESTED review at 3513f96 still gates this PR (reviewDecision: CHANGES_REQUESTED, mergeStateStatus: BLOCKED) although head eb2f843 carries only the four files that review asked to keep; dismiss or refresh it so the merge can proceed.

Intent alignment, delta re-review 393a120 β†’ eb2f843. The delta is a single Merge branch 'v5' bringing in #15694 (docs/repositories.md +4/βˆ’2, security-insights.yml +11/βˆ’3) β€” neither file is in the PR's diff, and the four PR files (src/pkg/github/pr_merge_state.go, src/pkg/github/pr_merge_state_commit_by_hive_test.go, src/docs/operator-reference.md, changelog.d/changed-15182.md) have identical blob SHAs at both heads. No new PR code to judge against #15182.

Prior finding Stale CHANGES_REQUESTED blocks a head that already did the requested split: still present β€” pr_fixer_rebase_signed.go and the rebase_merge_followthrough.go hook remain absent at head, matching item 1 of the 3513f96 review ("Keep the CommitByHive verified-signature tightening … + its test + changelog/doc line"), but the review state has not been updated. Nothing agent-fixable remains in scope.

β€” hive: agent=reviewer-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=adjudicator-3 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=reviewer-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision needed: @clubanderson should decide whether to accept that, after this lands, Rebase-then-merge on a dirty contributor PR settles failed (foreign-head) until the fixer host signs its pushes with a key GitHub verifies against a pane-domain address.

Decision needed: @clubanderson should decide whether to accept that, after this lands, Rebase, then merge as maintainer on a dirty contributor PR settles failed (foreign-head) until the fixer host signs its pushes with a key GitHub verifies against a pane-domain address.

The code does what it says and I found no defect; I am routing it because it changes merge-trust policy and knowingly disables one operator flow.

What I verified against the v5 tree:

  • hiveCommitIdentity (src/pkg/github/pr_signed_reconcile.go:316-335) already returns false for any resolved login other than the App bot, so the new author clause authorLogin != "" && hiveCommitIdentity(...) reduces to "GitHub resolved the author to the App bot". The committer clause keeps login-resolved-to-bot as before and gates the email-domain / noreply-address path on verification.verified. Net effect is a strict tightening β€” nothing that was rejected before is accepted now.
  • The reasoning that GitHub's verification binds to the committer address, not the author, is correct; that is why the forged---author cases in pr_merge_state_commit_by_hive_test.go return false while "person author, email-only pane committer, verified" returns true.
  • GitHub's update-branch (author = App bot, committer = web-flow) still passes via the author clause, so the hive's own behind-only PRs are unaffected.
  • The regression is real and the PR documents it in both the doc comment and operator-reference.md:482: the fixer's rebase is a plain unsigned commit (push broker sets commit.gpgsign=false; the signed reconciler walks App-authored PRs only), so on a contributor PR the follow-through now fails closed and Approve the new head & merge is the only way through. Whether that trade is acceptable before the fixer signs is the owner's call, not mine.

Changelog fragment changed-15182.md is present. Could not run go test in this pod (blocked for agents); the test (rest …) shards are green on this head.

β€” hive: agent=reviewer-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Read against the tree at 5b1b3f0. The tightening is implemented as described and fails closed in the right direction.

  • The committerLogin != "" short-circuit at pr_merge_state.go:145 is safe because hiveCommitIdentity (pr_signed_reconcile.go:318-319) only returns true for a resolved login when it equals the App bot β€” a person's resolved login never reaches that branch, so "any login" here really means "the App bot".
  • Author-side: authorLogin != "" && hiveCommitIdentity(...) at :154 means email-only author matches are dropped entirely, which is the right call since GitHub's verification covers the committer identity only.
  • Consequence to be aware of (stated in the new doc comment at :119-123, not a defect): the sole caller is the rebase-then-merge follow-through (rebase_merge_followthrough.go:255), so an unsigned plain-git fixer rebase on a contributor PR now reports HeadByHive=false and the follow-through settles foreign-head instead of merging. That is the reversible, keep-work-moving option @clubanderson chose on #15182, so I am not raising it as a question.

go build ./pkg/github/ ./pkg/dashboard/ is clean. Looks correct to me. The conflicts-with-open-pr label is the only thing standing between this and green from what I can see.

β€” hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive

Copy link
Copy Markdown
Contributor Author

stage 100-merge-queue β†’ 060-reviewed: required-check-pending:Sign-off survives the squash

@hivecommons-hive

Copy link
Copy Markdown
Contributor Author

stage 060-reviewed β†’ 050-review-pending: required-check-pending:build-and-test

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=adjudicator-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=adjudicator-3 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision needed: @clubanderson should decide whether to accept that, with this change, "Rebase, then merge as maintainer" on a dirty contributor PR settles failed (foreign-head) after the fixer's unsigned rebase until fixer hosts sign their pushes β€” the price of no longer trusting a bare pane-domain committer email.

Conclusion: the code is correct and closes a real gap; I found no defect. I am routing it because it is a merge-trust policy change that knowingly regresses one operator path, and that trade is a maintainer's to accept.

The gap it closes (read at head a68a98d):

  • src/pkg/github/pr_signed_reconcile.go:316-327 β€” hiveCommitIdentity("", email) returns true for any address in the pane domain, by string match alone. Git author/committer emails are set by whoever pushes (git -c user.email=x@<pane-domain>), so on v5 a person pushing a new head after a maintainer's rebase-then-merge click could have it counted as the hive's rebase (pr_merge_state.go:131), merging content the approval never covered.
  • src/pkg/github/pr_merge_state.go:141-153 (this PR) β€” an email-only committer match now also requires commit.verification.verified; GitHub only marks a commit verified when the signing key's account owns the committer email, so the domain match is finally bound to a GitHub identity. Author matches by email are dropped entirely (:152), which is right: a signature says nothing about the author field. The 13-case table in pr_merge_state_commit_by_hive_test.go covers both forgeries and both legitimate shapes (update-branch, signed fixer rebase).

What it costs β€” stated by the PR itself, verified: the fixer's rebase of a contributor PR is a plain unsigned commit with a pane-domain committer (the PR body and operator-reference.md:482 say the push broker sets commit.gpgsign=false, and the signed reconciler only re-signs App-authored PRs). Under the new rule that head fails CommitByHive, so the dashboard follow-through in src/pkg/dashboard/rebase_merge_followthrough.go settles failed (foreign-head) instead of merging, and the maintainer must click Approve the new head & merge. That is a deliberate fail-closed choice, not a bug β€” but it changes what a merge-now click does on every dirty contributor PR until fixer hosts sign.

The automerge DCO path is unaffected: automerge_stage_dco.go:79-81 already uses commitByApp (login only) and does not call this function.

Changelog fragment and operator-reference row both describe the new rule and the prerequisite accurately.

β€” hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=adjudicator backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=adjudicator-4 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=adjudicator backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=ci-maintainer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

β€” hive: agent=adjudicator-3 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed β€” no findings from this perspective.

Delta a68a98d…7088ec12 is only the v5 merge of #15621 (pr_empty_diff_hive_autoclose.go, its test, changelog fragment); no PR-authored code changed. Prior security note (src/pkg/github/pr_merge_state.go:144, merge-trust policy change with accepted operational regression) no longer applies: the maintainer decision is on record in this PR (clubanderson, 2026-10-30T01:45Z: keep the CommitByHive verified-signature tightening, drop the signing step), and the PR now matches that shape β€” email-only committer match fails closed without verification.verified, author counts only by App-bot login (pr_merge_state.go:148-164).

β€” hive: agent=adjudicator-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive

Copy link
Copy Markdown
Contributor Author
Evidence bundle `#154057088ec1` sha256:e67d0ad695e7799732b1211a83fb4972c423de6fcf94426fa496a08a000abaa8 β€” download from the dashboard or `hivectl review evidence #15405`.

@github-actions

Copy link
Copy Markdown
Contributor

Thank you for your contribution! Your PR has been merged.

We'd love to hear how your experience was: share feedback

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author/hive This repository's own hive (the App or one of its agent lanes) authored this PR conflicts-with-open-pr Open PR has a merge conflict with another open PR copilot dco All commits are DCO signed-off dco-signoff: yes Indicates the PR's author has signed the DCO. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Review backlog (correctness): Previous security finding (merge/trust policy expansion) unchanged at new head

1 participant