Skip to content

feat(auth): enable guests to access sessions through selected mentions - #184515

Merged
roboclaw-bot merged 3 commits into
mainfrom
fix/guest-access-13-guest-invitations-20261026
Nov 17, 2026
Merged

roboclaw-bot merged 3 commits into
mainfrom
fix/guest-access-13-guest-invitations-20261026

Conversation

@vincentkoc

@vincentkoc vincentkoc commented Oct 26, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

Team guests need their own sessions, explicitly invited sessions and sanitized public links without discovering unrelated conversations.

User Impact

Enables opt-in gateway.roles.definitions.<role>.sessions.others: "invited" after the preceding read guards. A creator/admin selecting a person in a committed original message grants session membership. Plain text, replay and later Inbox delivery cannot grant access.

Visitor Access accepts the documented role for invitations and renewals. Ordinary invited readers need session access for attachments; real administrators retain standalone media access.

Why This Change Was Made

Prepare invitation authority at the authenticated human-input owner, retain approved offsets through recovery, and commit membership with the original transcript write. Retained readers observe the committed membership. Inbox notification failure has a visible outcome and does not undo a committed message or cancel agent dispatch.

Stack step 17/17, based on invitation UI wording. Review and merge in stack order. This PR owns full-stack integration coverage; preceding PRs retain their narrow production boundaries.

Contributor credit: @vincentkoc (PR author), with @jalehman (stack owner).

Work sessions

Linked for team reference; these sessions aren’t public.

Evidence

Current CI repair — November 17

Landed November 17: exact reviewed head 488654e4ec99930cfefeffe73d014329a7049181 merged as 62a982bb24b5. Final CI and required openclaw/ci-gate succeeded; the exact-head hosted review is Ready with no findings or before-merge items. Native replacement recovery used existing completed hosted CI, with no new CI dispatch, compute lease, writer switch or gate bypass. The landed commit retains exactly one credit trailer each for @vincentkoc and @jalehman.

Replacement candidate 488654e4ec99930cfefeffe73d014329a7049181 repairs the PR-caused session-identity ratchet failure. The previous pinned auto request was explicitly retired through its native owner before this head was published; it was not overwritten or re-armed blindly.

The permission hook now revalidates the current sender and approved recipient authority, leaving transcript/view preconditions with the existing session-store writer. A redundant caller-side transcript comparison is removed. Invited media policy consumes the prepared sharing owner's authoritative entry and membership instead of comparing two caller-side incarnation IDs. The identity allowlist is unchanged; the exact session-identity check now passes.

A new regression failed before and passed after this repair: refreshing descriptive caller metadata must not become an authorization refusal, while changing recipient eligibility still refuses the invitation and the original writer precondition remains intact. The affected repair run passed 87 cases with one stale error-text expectation; that expectation was corrected, and the failed case, new regression and all four actor/non-actor authority cases then passed (6 targeted cases). The media/resource cases were already green and unchanged by that expectation correction. No unresolved product assertion failure is hidden by a passing replay. The actual native composer flow passed 3/3 again on the repaired source. Core/methods types, scoped typed lint, committed diff, test-line and session-identity checks passed; fresh independent review of the repair is scoped-clean.

Net test growth is +3,505, standard allowance 400, exact credit 3,105, including this required regression; the reason is also in the squash body. No identity-ratchet allowance, protocol/schema version, default or permission gate was raised. The prior native AWS proof stays pinned to its original head/base below; no new lease or workload replay was used. Fresh replacement-head CI and the requested hosted review are tracked separately from the prior failed run.

Pre-repair integration qualification — 3e08c1f

Candidate 3e08c1f23dd553c2a109824cfb334138b354353f is based on 054fd9788bc0f86303e161ca3b2ab36a1ed8cd65. The new conflict was resolved by retaining main's administratorMemberPolicy alongside membership-aware canRead/canInvite, and preserving main's origin-owned continuation recovery. Main intentionally retired the large hello update-scope suite in #198943; this PR does not resurrect it. Canonical frames.auth.test.ts retains and passes the transport-schema cases, including invited.

On this candidate, 117 affected cases across 13 files passed, covering the seven guest consumers, selected-mention commit/replay/failure paths, current member-administrator policy, recovery authority, actor/non-actor transcript custody, native role config and canonical hello auth schemas. The actual native composer flow passed 3/3 again for none, view and explicit invited, with committed access, outsider exclusion, HTTP JSON/SSE, stop/start persistence and next-request revocation. Core/methods types, scoped lint/format, validators, canonical config-doc checks, committed diff checks and the exact test-line ratchet passed. Fresh independent P0–P2 review is scoped-clean.

Net test growth is now +3,484, with standard allowance 400 and exact allocation 3,084; the three-line reduction follows the upstream test consolidation. All remaining current-main tests are retained. The task-only browser driver is retained as evidence outside the checkout and is not shipped. The AWS execution below remains pinned to its actual tested head/base; it is not relabeled as a November 17 execution. Current mention/recovery/schema integration was requalified with the affected real-Gateway and native UI checks above. Final-head CI and one hosted re-review remain required before landing.

November 16 integration qualification — 10d2413

Prior candidate 10d24137b2562eb108b01f230851da3d69005da4 is based on a139d420834e6e04641303c79eb7c6e0e4444fa5. While AWS qualification ran, main advanced and conflicted only in generated config hashes. The canonical generator resolved that conflict. Range-diff shows no invitation-production delta; every production file changed by this PR is byte-identical to AWS-qualified e6193da7. Dependency and agent DB schema-version inputs did not change. The AWS proof below remains explicitly pinned to its tested head/base, not relabeled as a new-tree execution.

After integration, 41 focused cases across 10 files passed, including all 30 guest/resource/mention cases and main's new transcript-memory/skills consumers. The real native composer flow passed again 3/3 on this final candidate. Core/methods typechecks, scoped lint, all validators, exact test-line ratchet and committed diff checks passed; fresh independent P0–P2 review completed scoped-clean. The retained task-only browser driver was removed from the checkout and is not shipped in the PR. The earlier 444-case qualification is recorded separately below. Exact final-head CI and hosted re-review remain required before merge.

Pre-conflict qualification — e6193da

Tested revision e6193da716b1107e7b4375698fa76a13731d553a was replayed onto 60c112a1bfa94ea4a5d43e4302e18375429d879f, after merged #184514. Range-diff preserves the original activation slice. The enum now lives in main's extracted src/config/zod-schema.gateway-roles.ts; main's OpenClaw ID connection ceilings, mention ranking/display identity and recovery-unavailability handling remain intact. Generated config metadata was regenerated, not hand-edited.

  • 444 scoped cases across 29 files passed, including original-message commit/replay, queued recovery, invitation-aware RPC/HTTP/event/resource consumers and Visitor Access. 3/3 real native Control UI scenarios passed locally for none, view and invited, through actual picker selection and Send, committed access, outsider exclusion, HTTP JSON/SSE, Gateway stop/start and next-request revocation. No enum/auth overlay is used.
  • Core and Gateway methods/server/root test type graphs, scoped typed lint/formatting, all five validator checks and the exact test-line ratchet passed. Independent P0–P2 source review completed scoped-clean for this head.
  • Idle and queued Inbox failures emit targeted mentions.failed without undoing committed input/membership or failing dispatch. Native queued replay forwards only the profile reauthenticated by the existing Gateway recovery owner; its two invitation regressions failed without that handoff and pass with it.
  • Config/schema delta: add only the literal invited to gateway.roles.definitions.<role>.sessions.others; extend Visitor Access eligibility to explicitly configured invited roles; regenerate config documentation hashes. No new key, shipped default change, DB schema/version change, protocol-version bump, Doctor transform or config migration. The already registered mentions.failed event is now emitted to the original sender’s connections on post-commit notification failure, carrying gatewayInstanceId, sessionKey, agentId, messageId and a fixed errorMessage; no new RPC or event schema is introduced. Existing absent/none/view behavior remains unchanged.
  • Net test growth +3,487, standard allowance 400, exact justified allocation 3,087 in config/test-lines-allocations/184515-guest-invitation-access.txt. All current-main tests are retained. Two obsolete pre-activation expected-error comments were removed without removing assertions.
  • Exact-head CI and required CI gate succeeded. Hosted exact-head re-review is the remaining source-review follow-through; no merge is claimed here.

AWS native acceptance — November 16

Head e6193da716b1107e7b4375698fa76a13731d553a and base 60c112a1bfa94ea4a5d43e4302e18375429d879f both built successfully on one isolated AWS c7a.8xlarge (measured 32 CPUs / 62,909 MiB), with Node 24.22.1 and pnpm 12.15.0. The native config is used without an enum/auth overlay. The identical task-only browser driver and fixture bytes were injected on the base only after its clean production build.

Native policy Expected Actual
none, head and base Uninvited guests cannot read the owner’s session or be selected for a notification/invitation. Matched: picker eligibility false; guest/outsider lists and reads exclude the session; HTTP 404; no membership.
view, head and base Preserve existing shared-session reads, including unrelated role-view readers; selected mentions do not add membership. Matched: actual composer selection + Send, retained message, guest/outsider access, HTTP JSON/SSE 200; no membership.
Explicit invited, head Creator A selects B; only the committed message grants access. C stays excluded. Revocation applies on the next request; Gateway stop/start retains the committed state. Matched through the actual composer, native TLS/WebSocket RPC and HTTP: B lists/reads/events/JSON/SSE work after commit; C remains excluded; stop/start preserves B’s access/message; A removes B and its next list excludes the session and read/HTTP requests return not found.
Inbox failure, head Targeted mentions.failed without failing idle or queued dispatch. Matched in both fault-injected handler integration cases; committed input and membership remain intact.

The AWS runs completed 3 head browser cases + 2 base comparison cases, 30 real-Gateway/resource and dispatch-failure cases across 8 files, and two CLI Doctor upgrade cases: frozen released-schema preservation and a replay through the actual stable 2026.11.4 CLI before candidate none → invited → invited. Memberships, exact retained transcript bytes and hidden-profile mention watermarks are preserved. This is isolated service stop/start and CLI upgrade proof, not a deployment or crash-reboot claim. No live Team Gateway configuration or deployment was changed.

The workload exited 0. Its complete evidence archive was downloaded and all 19 artifact hashes verified; head/base driver-input hashes match. Archive SHA-256: a4abbe5737b07ef80deccaea6f897033b2a6ad67974075edcb075626692abbef.

Provider recovery and cleanup verified: the workload originally exited 0 but the CLI wrapper exited 7 after coordinator finish/release/inspection requests returned HTTP 401. After access returned, the missing original receipt was inspected and recovered using its unchanged signed finish file, signer and finish hash—no workload replay or replacement lease. A fresh server read verifies the original terminal receipt with exit 0. Normal release succeeded, and authoritative inspection reports state=released, hasHost=false, ready=false, cleanupStatus=complete and provisioningResourceMayExist=false (cleanup completed November 16, 14:57:58 UTC). The retained archive checksum still matches after release, and local owned SSH transport termination is confirmed. Verified run record; lease cbx_da8d965348dd. This task changed no credentials, account, provider or live Gateway configuration to recover it.

Interrupted earlier qualification

At f9377634, exact-head CI and its CI gate succeeded. The November 14 AWS run reported successful head build, frozen-schema Doctor upgrade, actual stable 2026.11.3 Doctor upgrade and all three native public composer scenarios before controller transport was interrupted (exit 255). Base proof and the remaining boundary run were not collected as completed; this is partial evidence, not full-stack AWS success. Lease cbx_e030bc31ff62 was subsequently verified expired with no host or possible remaining provisioning resource, cleanup timestamp November 14 09:21 UTC. The November 15 local continuation ended by SIGTERM/143, not a product assertion; those incomplete gates have now been rerun to terminal receipts above.

Earlier stack qualification (historical heads, not current-head proof)

Final integrated source: 47b8b4485615af059ec8d93047057099289a57f7, on fixed main 5bf0c41a03f1dba03d625460607ed5b959710458. All 18 post-base commits are signed. The rebase preserves main's Access-program grants and runtime-label filtering, adopts its canonical Doctor/lifecycle/harness fixtures, and removes duplicate prerequisite fixes. Canonical config metadata is regenerated. Prefixes are not separately built locally; current-head CI and review receipts are recorded on each PR.

Qualification

The complete integration matrix passed 46/46 across 13 files and four configurations under pinned Bun in 374.85 seconds, at the previous published head ddc49fd63d3b82e41eb6c74af4ad935a56aebc8f. This is pre-rebase proof, not a claim that these local results ran at the new head.

{"head":"ddc49fd63d3b82e41eb6c74af4ad935a56aebc8f","result":"pass","runtime":"pinned Bun","files":13,"tests":46,"transport":"authenticated TLS/WebSocket and HTTP","provider":"loopback fixture","scope":"complete guest-access stack before fixed-main rebase"}

Before the rebase, eight affected type graphs passed: core, agent/session, config/CLI, Gateway root, Gateway server, Gateway methods, messaging and Doctor commands. Typed lint, formatting and line caps passed. Current source passes git diff --check; the canonical worker inventory reports 695 non-test files / 2,482 call expressions with unchanged classifications.

The pre-rebase Doctor/session-visibility fixtures passed 45/45 under pinned Bun in original order; session-read and conversation-capture fixtures passed 39/39 under Node. Main now owns the Doctor repair. The callback-retention regression failed 2/4 before the fix and passed 4/4 afterward, including collected inputs. Scoped autoreview completed with no actionable P0–P2 findings; an independent source review found no introduced defect, including the overlapping main changes.

Runtime coverage uses canonical profiles, membership stores and resource owners:

  • Authenticated TLS/WebSocket inventory/history: owned access, unrelated denial, original selected-mention grant, Inbox deduplication, removal and replay denial.
  • Project/task/metadata reads: member success, unrelated filtering and revocation after repository or placement preparation.
  • Events: parent/child ancestry, current viewers/presence and revocation while a text event waits in the real send queue.
  • Collaboration: question get/list/wait/events, companion results and retention, process reads, reactions, suggestions and deferred typing. Existing scope limits remain independent of membership.
  • HTTP/resources: ordinary attachment bytes, remote widget HTML, artifact tickets, history JSON and an established SSE stream. Removal after preparation prevents bytes/events; old tickets remain denied.
  • Aggregates: persisted usage/counts, cron preview, execution-approval reads/waits/events and explicit global-cost/archive denial.
  • Provider dispatch: real subagent transport to a loopback HTTP fixture; removal after DNS/SSRF preparation prevents the next request.
  • Original-message commit: actor/non-actor SessionManager writes using real Inbox authority; sender demotion at native commit rolls back transcript events, membership, watermarks and retained-reader visibility.

These are call-through pauses at production boundaries, not replacement authorization guards. Event/process fixtures are synthetic. The provider case exercises the production runtime caller, not the authenticated WebSocket fork entry. The GitHub case reads a persisted canonical receipt and makes no GitHub API call. UI captures establish wording/layout only.

CI fixture repairs

Three separate prerequisites repair the failures found during qualification:

  • Worker preparation: the selector tests passed 43/43 and the complete admission file passed 168/168 under pinned Bun. A negative admission fixture now excludes the new subscription consumer; the corrected negative case and positive compiler sibling passed 2/2 under Node. A cold full-path subscription run passed 65/65, with 70.08 seconds of native preparation completed before the unchanged watchdog. Basename selection and exclusions are covered by the final selector tests.
  • Coordination cleanup: the full file passed 30/30 under pinned Bun after removing its premature synchronous database close and moving both ACP databases into the canonical fixture. Both old external-path cases failed the new native-handle retirement assertions; the repaired cases passed 2/2 under Node. Cleanup drains borrowers and closes the retained native handle before removing directories.
  • Chat startup admission: the uninstrumented orphan-recovery file passed 2/2 after using the existing startup endpoint. The prompt-cache start/restart sibling passed 1/1 with startup tracing; its earlier 90-second setup timeout remains unattributed.

The earlier fixture-repair qualification passed Tooling and Gateway-server typechecks and scoped typed lint. The ACP correction passed formatting and the canonical test-line ratchet; scoped autoreview found no actionable P0–P3 findings. This restack preserves all production changes and downstream source patches. Its only additional source change is canonical ACP fixture ownership with native-handle retirement assertions, plus the measured three-line correction to prefix ceilings. Final tree: 3bf325279a93b2437f4051ba172033f45a172ffb. Local results are scoped evidence; each revised prefix also has passing hosted CI and a source review with no actionable findings at its published head.

Earlier build and upgrade qualification

At 5cd3488508bfbd52b4c59ad7736f84831e60ed22, the full QA build passed in 288.09 seconds, including declarations, plugin/runtime packaging, CLI bootstrap, SDK export resolution and Control UI budgets. Seven affected type graphs, 29 RPC cases on both Node and pinned Bun, and 74 integration cases under pinned Bun passed. The real built CLI upgrade passed under both engines, preserving memberships, exact transcript bytes and the hidden-profile watermark through none → invited → invited using the v2026.10.7 schema and real doctor commands. This is CLI upgrade proof, not npm-install or deployment proof.

The later guest-access production repair releases settled invitation callbacks and moves their binder within the existing live-owner module; the 46-case integration run qualifies that lifecycle change. The new main rebase also preserves upstream production changes. Dependency, packaging and public export inputs are unchanged; the current-head hosted CI run linked below supplies the final prefix qualification.

Retained broader regressions: 102 cases across six files at 63c46cb89897c1e6fe496d55af5f42c152506b0c, and 136 passing cases across 12 files at 979ff80bf2e59f7ea0a10c2ec4ce6ffbb045f6b4. These cover notification failure, ticket revocation, cold transcript restoration, actor residency, subagent completion, private-session reads, mixed durable/private usage and eight forged-SDK-options paths. The latter run's failing cleanup fixture is fixed in the prerequisite and subsequently passed 17/17 on both engines.

The unmodified SDK surface gate failed at both the runtime-qualified revision and merged base: 160 entrypoints > 158, 3,832 exports > 3,818, 2,223 callable exports > 2,214. Neither reported unauthorized removals from v2026.10.7. Matching counts are not proof of identical exports; this remains recorded baseline debt. No SDK budgets were raised. The separate, measured test-line allowance is documented below.

Review follow-through

The retention finding is fixed in the transcript owner. Actual terminal release clears the closure; collected inputs retain live source checks; unknown-outcome custody remains intact. The new integration matrix closes the requested publication/resource coverage gaps.

Earlier fixes remain: broad question preparation includes membership; public SDK options cannot supply invitation authority; post-commit Inbox failure reports failure while preserving dispatch. The concurrent RPC publication repair retains its authorship and unrestricted retired-store deduplication.

Named follow-up: the delivered-event thinking-claim CI failure did not reproduce in paired full-file runs on the same Bun pin: 3/3 at parent 0430e197cfca4233e76fbaccae4e6536bf37b19a and 3/3 at event head 0db3b01bf4e02cdab7fb7cd4d5833dfe201993bb. Its owner/callers/fixture are unchanged and bypass the changed broadcaster. Local macOS proof does not establish the Linux CI cause; investigate claim retirement if it recurs.

Trusted local qualification followed the unavailable Testbox allocation, which ran no tests. Current-head hosted CI and review remain required before landing.

Current-head qualification

Required CI passed at 47b8b4485615af059ec8d93047057099289a57f7. The ClawSweeper review covers the same head and reports no actionable findings or required rank-up moves. Merge in the recorded stack order.

Change size

Current restack: 52 files, +4,126/-291. Historical prefix accounting: production +392/-117; tests +3832/-808; docs +53/-11; generated +2/-2.

Positive production LOC adds the invitation authority boundary and opt-in role capability. No new config key, changed existing default, SQLite schema-version bump or protocol-version bump. Enable invited for the intended role and reconnect its profiles. Existing view roles remain supported. Public access means the existing sanitized public transcript link.

Fixes #135631. Context: #135631.

Stack order

  1. invitation-only role policy (merged)
  2. filter session discovery by membership (merged)
  3. repair fixtures and refresh worker inventory
  4. recheck access before RPC reads return
  5. scope live events and Inbox notifications
  6. guard collaboration reads and interactions
  7. prepare native workers before the test watchdog
  8. guard HTTP resources and session tickets
  9. filter project and task summaries
  10. filter usage, cron and approval lookups
  11. retire coordination fixtures through canonical cleanup
  12. wait for public startup admission in chat fixtures
  13. commit membership and involvement together
  14. commit invitations with original messages; release retained authority
  15. preserve invitation authority through runtime writes
  16. explain invitations and show delivery failures
  17. enable invited roles; add full-stack behavior tests

Historical test-line allowance (superseded above)

config/test-lines-baseline.txt: 6,284,088 → 6,287,107 (+3,019). Adds the real-owner integration matrix and upgrade coverage, while removing replaced synthetic cases. The allowance includes test-support files and uses the canonical full-tree counter. The ceiling equals this prefix's measured 6,287,107 test lines; no spare allowance is added. This is a bounded baseline exception under the repository testing workflow, not a functional-test waiver. No runtime assertion, SDK budget or required CI check is weakened. Change-size test counts include the baseline metadata edit.

Across the open stack, the test-line ceiling rises by 4,868: 4,396 measured net test lines plus 472 already present on the fixed main. Each increase is folded into its owning slice; assertions and runtime behavior are unchanged by the budget edits.

@vincentkoc vincentkoc self-assigned this Oct 26, 2026
@clawsweeper

clawsweeper Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation gateway Gateway runtime plugin: visitor-access size: XL labels Oct 26, 2026
@clawsweeper clawsweeper Bot added the clawsweeper:intake:feature Preliminary submission classification; full source review pending. label Oct 26, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. and removed clawsweeper:intake:feature Preliminary submission classification; full source review pending. labels Oct 26, 2026
@clawsweeper

clawsweeper Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR enables invitation-only roles and grants session membership when a creator or administrator commits a selected human mention.

Example: Alice selects Bob in a shared conversation with Bob’s role configured as sessions.others: "invited".

  • Before: The configuration rejects "invited", so Bob cannot receive invitation-only access through the native flow.
  • After: Committing Alice’s selected @bob mention grants Bob membership while unrelated Carol remains excluded.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) Useful and supported by native behavior and stable-upgrade evidence, with no actionable introduced finding; routine exact-head CI remains pending.
Proof confidence 🐚 platinum hermit (4/6) Sufficient (live_output): The supplied native composer results exercise actual selection and Send for none, view, and invited, including committed access, outsider exclusion, HTTP JSON/SSE, restart persistence, and next-request revocation; the repaired head records the same composer scenarios again, while earlier AWS and upgrade evidence remains correctly pinned to its tested revision.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Feature · Worth it: Yes · Fix scope: Complete
User problem: Team operators cannot expose exactly the conversations a guest is invited to while keeping unrelated conversations hidden.
Reason: The linked deployment reports establish the need, and this maintainer-authored direction adds an explicit mode rather than changing existing permission ceilings.

Merge readiness

✅ Ready for maintainer review

Keep open: this maintainer-authored PR completes useful invitation-only guest access that current main cannot enable. No actionable introduced defect was found; the exact-head CI gate remains pending.

Priority: P2
Reviewed head: 488654e4ec99930cfefeffe73d014329a7049181

Before merge

None.

Findings

None.

Agent review details

How this fits together

The Gateway authenticates human chat input, prepares invitation authority, and sends it to the existing transcript transaction owner; committed membership then controls session discovery, reads, events, and attachments.

flowchart TD
A[Selected human mention] --> B[Authenticated chat input]
B --> C[Invitation policy]
C --> D[Transcript transaction owner]
D --> E[Committed membership]
E --> F[Session reads and media]
D --> G[Mention Inbox notification]
Loading

Technical review

Best possible solution:

Complete the opt-in activation through the existing input, transcript, membership, and media owners after the exact-head CI gate passes.

Do we have a high-confidence way to reproduce the issue?

This is feature activation: current main’s native schema rejects invited, while the supplied acceptance results exercise selected-mention grants and unrelated-user exclusion.

Is this the best way to solve the issue?

The change uses the existing policy and transaction owners, preserves existing settings, and keeps notification delivery separate from committed membership; no smaller missing production boundary was identified.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 5275f4391911.

Provenance checked

  • Selected mentions and access grants changes intended behavior with a stated reason (516fbb2: Selected mentions notified eligible people after fresh human-message commits and did not themselves grant access.)
  • Transcript transaction ownership keeps the original intent (baca36e: Commit invitation effects and involvement watermarks atomically with fresh original messages while preserving replay denial and private authority custody.)
  • Queued input recovery keeps the original intent (2d9033c: Recover accepted inputs with original identity, FIFO ordering, and current operator authority.)
  • Connection permission ceiling keeps the original intent (bd88401: Keep mention access within the connecting client’s permissions even when its linked profile has broader authority.)
  • Worker-backed Inbox persistence keeps the original intent (8d86209: Move Inbox persistence through existing workers while retaining deprecated synchronous adapters and post-commit delivery ownership.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

What I checked:

  • Current main still lacks activation: Fetched main accepts none, view, suggest, and write in the native role schema; the introduced diff adds invited without changing existing defaults. (src/config/zod-schema.gateway-roles.ts:35, 5275f4391911)
  • Invitation authority stays at human input: Only retained selected mentions from the original human input prepare invitations; the policy limits grants to creators or administrators and explicitly configured invited recipients. (src/gateway/server-methods/chat-user-turn-recorder.ts:358, 488654e4ec99)
  • Existing transaction owner prevents replay grants: The merged transcript owner applies invitations only after a fresh original insert, within the transcript transaction, and validates the retained expected entry. (src/config/sessions/session-mention-invitation.ts:8, 488654e4ec99)
  • Earlier notification finding resolved: Post-commit Inbox failures produce a targeted mentions.failed event and are caught before they can cancel agent dispatch; idle, queued, and recovered-input cases cover this boundary. (src/gateway/server-methods/chat-user-turn-recorder.ts:411, 488654e4ec99)
  • Concrete user need and canonical report: [Bug]: Session list ignores explicit membership, leaving no way to scope visibility to invited sessions #135631 documents the missing middle ground between none and view; sense33ai888 and sepehr500 describe team deployments, while ceckert describes a downstream membership implementation seeking the upstream contract.
  • Native behavior and upgrade evidence: The full body records native composer success for none, view, and invited on the repaired source, plus pinned AWS acceptance and an actual stable 2026.11.4 CLI upgrade preserving memberships, transcript bytes, and mention watermarks; inspected images establish historical UI wording only. Captured body identity: b19544460b391419f96257816205d3473b0c4853e5e9e85be7a46422d505ae3e. (488654e4ec99)

Likely related people:

  • Vincent Koc: Raw commit baca36e adds src/config/sessions/session-mention-invitation.ts:9 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: baca36ea403c; files: src/config/sessions/session-mention-invitation.ts)
  • Peter Steinberger: Raw commit 516fbb2 adds src/gateway/human-mention-policy.ts:110 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 516fbb224bf8; files: src/gateway/human-mention-policy.ts)
  • Josh Lehman: Raw commit 35b110b adds src/gateway/human-mention-policy.ts:165 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 35b110b0cfc5; files: src/gateway/human-mention-policy.ts)
  • Josh Avant: Raw commit bd88401 adds src/gateway/human-mention-policy.ts:175 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: bd884017b2d9; files: src/gateway/human-mention-policy.ts)

PR surface

Source +281, Tests +3510, Docs +42, Generated 0, Other +2. Total +3835 across 52 files. Added test files: 11.

View PR surface stats
Area Files Added Removed Net
Source 14 398 117 +281
Tests 31 3673 163 +3510
Docs 5 51 9 +42
Config 0 0 0 0
Generated 1 2 2 0
Other 1 2 0 +2
Total 52 4126 291 +3835

Preflight source

Source 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

Metric Value Why it matters
Configuration surface One new enum value; zero new config keys or changed defaults The invited value makes selective session access explicitly opt-in while retaining existing none and view behavior.

Labels

Label changes:

No label changes.

Label justifications:

  • P2: Useful, explicitly configured team collaboration capability with limited blast radius and no demonstrated urgent regression.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.
  • proof: sufficient: Contributor real behavior proof is sufficient.

Rating scale

6/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.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

History

Review history (9 earlier review cycles; latest 8 shown)
  • reviewed 2026-10-27T11:56:34.958Z sha 0db7344 :: needs real behavior proof before merge. :: none
  • reviewed 2026-10-27T13:17:05.796Z sha a2e1f7176ea33d951dbda91c9dff4b8ad8fac00a :: needs maintainer review before merge. :: none
  • reviewed 2026-10-27T13:25:40.507Z sha a2e1f7176ea33d951dbda91c9dff4b8ad8fac00a :: needs maintainer review before merge. :: none
  • reviewed 2026-10-27T14:22:47.517Z sha 7d174f95505ac298e0ce0f3c03a93c25fb39e0ad :: needs maintainer review before merge. :: none
  • reviewed 2026-10-27T14:48:56.861Z sha ec5a3f52181f3f5a57d3d0a0747556ef4a02a5b8 :: needs maintainer review before merge. :: none
  • reviewed 2026-10-27T15:06:40.951Z sha 47b8b44 :: needs maintainer review before merge. :: none
  • reviewed 2026-11-16T15:28:58.875Z sha 10d2413 :: needs maintainer review before merge. :: none
  • reviewed 2026-11-17T03:48:01.310Z sha 3e08c1f :: needs maintainer review before merge. :: none

Reviewed November 16, 2026, 11:18 PM ET / November 17, 2026, 04:18 UTC (Revision 10).

@roboclaw-bot
roboclaw-bot force-pushed the fix/guest-access-12-mention-ui-20261026 branch 2 times, most recently from 01f0f9c to 385c716 Compare November 14, 2026 07:28
Base automatically changed from fix/guest-access-12-mention-ui-20261026 to main November 14, 2026 07:43
@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui scripts Repository scripts labels Nov 14, 2026
@github-actions

github-actions Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Security-sensitive guard cleared

Current revision: 488654e4ec99930cfefeffe73d014329a7049181

This PR no longer changes files in the maintainer security-review tier.

Separate CODEOWNERS requirements still apply to security policy and enforcement files.

@roboclaw-bot
roboclaw-bot force-pushed the fix/guest-access-13-guest-invitations-20261026 branch from 47b8b44 to 3671982 Compare November 14, 2026 08:45
@openclaw-barnacle openclaw-barnacle Bot removed app: web-ui App: web-ui scripts Repository scripts labels Nov 14, 2026
@roboclaw-bot
roboclaw-bot force-pushed the fix/guest-access-13-guest-invitations-20261026 branch 2 times, most recently from e6193da to 10d2413 Compare November 16, 2026 15:18
@roboclaw-bot

Copy link
Copy Markdown
Collaborator

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

roboclaw-bot and others added 2 commits November 17, 2026 03:26
Preserve existing none/view defaults and main coverage. Forward the reauthenticated Gateway profile during native queued replay so committed invitations retain their real requester.

Co-authored-by: vincentkoc <[email protected]>
Co-authored-by: jalehman <[email protected]>
The enum activation makes these two pre-activation expected errors obsolete. Keep all four runtime assertions and decrease the allocation by exactly the two removed comment lines.

Co-authored-by: vincentkoc <[email protected]>
Co-authored-by: jalehman <[email protected]>
@roboclaw-bot
roboclaw-bot force-pushed the fix/guest-access-13-guest-invitations-20261026 branch from 10d2413 to 3e08c1f Compare November 17, 2026 03:37
@roboclaw-bot

Copy link
Copy Markdown
Collaborator

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

Revalidate current sender and recipient authority without comparing caller transcript descriptions. Consume the sharing owner entry for media membership, and remove a redundant caller-side incarnation comparison. The new ownership regression fails before and passes after this repair; writer-side fencing and demotion rollback remain enforced.

Test allocation is exactly 3,105 lines above the standard 400 for net +3,505, including this required regression. The identity allowlist is unchanged.

Co-authored-by: vincentkoc <[email protected]>
Co-authored-by: jalehman <[email protected]>
@roboclaw-bot

Copy link
Copy Markdown
Collaborator

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@roboclaw-bot

Copy link
Copy Markdown
Collaborator

Merged via squash.

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

Labels

agents Agent runtime and tooling clawtributors PR from a clawtributor docs Improvements or additions to documentation gateway Gateway runtime P2 Normal backlog priority with limited blast radius. plugin: visitor-access proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: XL status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Session list ignores explicit membership, leaving no way to scope visibility to invited sessions

2 participants