Repository navigation
fix: require explicit opt-in for Session Share readers - #202299
Conversation
OpenClaw-Publication: daadcf7c-719e-890e-823a-a1b453d00439
|
🦞👀 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. |
OpenClaw-Publication: 67e30e31-ddaf-81f3-a509-b3dee54e0032
|
Maintainer review at Formal review (autoreview, branch mode against
What I checked by reading
Not verified here
One docs nit, not blocking: the new "Publication reader opt-in" section in |
|
Codex review: blocked before merge. What this changesThis PR adds an explicit host opt-in for Session Share readers and permanently retires existing admissions when access is disabled. Example: A paired device requests operator.session-share.read without gateway.sessionControl.publicationReadEnabled.
Review scores
ProductKind: Feature · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Blocked before merge - 3 items remain Keep this maintainer-authored PR open: the approved hardening remains absent from main, but the change misses an existing reader fixture and reports disabled access as a token problem. Priority: P2 Before merge
Findings
Tests
Agent review detailsHow this fits togetherThe Gateway admits signed reader devices, restricts their RPC methods, and passes authorized reads to the Session Share plugin for source selection and disclosure. flowchart LR
A[Signed reader device] --> B[Gateway admission]
C[Committed runtime config] --> B
C --> D[Reader currentness]
B --> D
D --> E[Session Share source grants]
E --> F[Selected session response]
Technical reviewBest possible solution: Keep the opt-in in the existing reader and config owners, update the signed-WSS fixture, and return an actionable disabled-access diagnostic. Do we have a high-confidence way to reproduce the issue? Current main visibly admits valid singleton reader tokens without a host opt-in; source inspection also establishes the missed fixture and misleading rejection path, without executing tests. Is this the best way to solve the issue? The existing config publication and reader-currentness owners are appropriate for the approved policy, but the cutover must include the existing production-path fixture and handshake diagnostic. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 477b61117416. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource +43, Tests +204, Docs +18, Generated 0. Total +265 across 18 files. Added test files: 2. View PR surface stats
Preflight sourceSource unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified. Review metrics
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed November 20, 2026, 1:54 AM ET / 06:54 UTC. |
OpenClaw-Publication: fab0b809-a45d-8e5c-8418-4836bb5facd7
|
Follow-up at
|
OpenClaw-Publication: 72a30543-8850-8df4-922b-8edd45acf540
|
Checked The review above applies to this head, and to any later head that differs only by a rebase plus regenerated files under |
|
Merged via squash.
|
* fix(gateway): require explicit publication reader opt-in * test(gateway): opt reader issuer-rotation fixture in explicitly * fix: require explicit opt-in for Session Share readers OpenClaw-Publication: daadcf7c-719e-890e-823a-a1b453d00439 * fix(gateway): require explicit publication reader opt-in * test(gateway): opt reader issuer-rotation fixture in explicitly * Merge 41a12bf * fix: require explicit opt-in for Session Share readers OpenClaw-Publication: 67e30e31-ddaf-81f3-a509-b3dee54e0032 * test: opt in signed Session Share publication fixture * Merge 404c49a * Publish openclaw/clear-krill OpenClaw-Publication: fab0b809-a45d-8e5c-8418-4836bb5facd7 * fix(gateway): require explicit publication reader opt-in * test(gateway): opt reader issuer-rotation fixture in explicitly * test: opt in signed Session Share publication fixture * Merge d382168 * Publish openclaw/clear-krill OpenClaw-Publication: 72a30543-8850-8df4-922b-8edd45acf540 Co-authored-by: Vincent Koc <[email protected]> Co-authored-by: vincentkoc <[email protected]>
What Problem This Solves
A signed Session Share reader could connect without an explicit host opt-in. Disabling and restoring access could also revive an already prepared reader handshake or response.
User Impact
Reader access is now off by default. Operators who use it must set
gateway.sessionControl.publicationReadEnabled: trueand retain the existing Session Share source opt-in and device grant. Disabling access permanently retires old admissions; re-enabling requires a fresh connection. Ordinary authenticated clients are unchanged.Why This Change Was Made
Record disable transitions at the committed config owner, then check that retained identity during reader admission, attachment and final disclosure. Unrelated config changes preserve valid readers. This is reader-only hardening: no steering, writer, discovery or source-selection APIs.
Evidence
41a12bfc864f775a97e13e5814643ae99ee1ef82(treee86b6f1c5161bad8b44c5af413fa2167c4e6c7cb): all 158 focused tests passed again, including six shared-auth-rotation cases. Scoped types, lint, generated config baseline, formatting and diff checks passed.eda78a0247ceaea9f18a3558bf5e18cf8365f52a; tree08331da09f2bd4411d6949cc93d962fb95a1bfc8.aacc34d66441c1e32725a020f2b9140f8519ee14(436s); it is historical evidence, not a fresh full build of the rebased candidate. Exact-head CI remains required.3e7c305f4572a0ce0407b112db1d5c2048da2624; regenerated only the config baseline (including main's additional plugin config entry). Both authored source/test patches are unchanged by range-diff. No writer, steering, discovery or source-selection changes.