Repository navigation
fix(mcp): require owner for Claude permission replies - #136924
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
@clawsweeper re-review Canonical security backport |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Codex review: blocked before merge. Reviewed September 7, 2026, 3:56 PM ET / 19:56 UTC. ClawSweeper reviewWhat this changesThe PR carries authenticated sender ownership through transcript events so only owner user replies can resolve Claude permission requests. Merge readiness⛔ Blocked before merge - 4 items remain Keep open: this remains a useful extended-stable security backport, despite the original fix already shipping on main. No introduced correctness defect was found; frozen-build validation and release acceptance remain outstanding. Priority: P1 Review scores
Verification
How this fits togetherOpenClaw’s MCP bridge connects Gateway conversations to an external Claude session. It converts qualifying chat replies into permission decisions while forwarding other user messages as ordinary conversation events. flowchart LR
A[Channel or Gateway message] --> B[Authenticated ownership decision]
B --> C[User transcript and live event]
D[Pending Claude permission] --> E[Owner and request check]
C --> E
E -->|Owner reply matches| F[Claude permission notification]
E -->|Otherwise| G[Ordinary conversation event]
Decision needed
Why: The security direction is already established upstream, but acceptance of the frozen release’s compatibility change remains a release-owner decision. Before merge
Agent review detailsSecurityNone. PR surfaceSource +31, Tests +102, Docs 0, Other +48. Total +181 across 16 files. View PR surface stats
Review metrics
Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Retain the canonical owner-only boundary and qualify the adapted frozen build, with explicit release acceptance of replies lacking ownership metadata remaining unable to approve. Do we have a high-confidence way to reproduce the issue? Yes, for the extended-stable base: a matching non-admin user reply reaches permission resolution without an owner predicate. Current main and v2026.9.2 already contain the guard; no runtime reproduction was executed in this review. Is this the best way to solve the issue? Yes, this is the appropriate bounded backport: reuse ingress authorization and enforce it at the permission notification boundary. A separate allowlist or permissive compatibility mode would duplicate policy or preserve the bypass. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against c688a95c34f1. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (4 earlier review cycles)
|
|
@clawsweeper re-review exact current head; please confirm only current actionable findings and rank-up moves. |
|
🦞🧹 I asked ClawSweeper to review this item again. |
* fix(mcp): require owner for Claude permission replies * fix(mcp): prove owner-gated permission replies (cherry picked from commit b885c81)
e14596d to
e3e42a6
Compare
Summary
Backports
b885c81479d(fix(mcp): require owner for Claude permission replies (#98256)) to the frozen extended-stable candidate.The exact frozen MCP lane showed the candidate consumes a matching
yes abcdefrom any user as an MCP permission response. A non-admin Gateway client can therefore resolve an outstanding Claude permission. This backport carries the authenticatedsenderIsOwnerfact from ingress through the persisted user turn and session broadcast, then makes the MCP bridge resolve only an owner user reply. Non-owner or unproven replies remain ordinary channel messages.Evidence
33709410737, MCP channels job100506487790; expected non-owner channel-forwarding timed out because the candidate consumed it as a permission response.src/mcp/channel-bridge.tshandlespermissionMatchbefore queue/Claude channel delivery, without a role/owner predicate.b885c81479dis absent from frozen candidate659df810and is the canonical owner-boundary repair.senderIsOwner; the unrelated upstream idempotency-key assertion was not added because the candidate lacks that precondition.Validation
node scripts/run-vitest.mjs run src/mcp/channel-bridge.test.ts src/mcp/channel-server.test.ts src/gateway/server-session-events.test.ts src/sessions/user-turn-transcript.test.ts— 60 passed.node scripts/run-vitest.mjs run src/gateway/server-methods/chat.directive-tags.test.ts src/auto-reply/reply/get-reply-run.media-only.test.ts— 343 passed.git diff --check; formatting; autoreview passed.Scope
Production +52 / -9; tests +148 / -3; docs +1 / -1. This is a source-compatible security/lifecycle backport. No config schema, package, tag, npm, or candidate ref mutation is included.