Repository navigation
feat(openclaw-id): add the Control UI account menu, linking dialogs and the Access page - #192352
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review blockedAutomated review did not run, so no review verdict was produced. Reason: The input-safety check rejected material in this revision. No detected value, path, or scanner output is reproduced here. Automatic review is on hold, including after source changes. Request a fresh re-review after resolving the failure; maintainers can also release the hold through an intentional scanner-policy update. Next step: If this is a genuine credential, remove and rotate it. If it is an intentional test fixture, a maintainer must review and qualify it. |
|
Local
|
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
6a53361 to
c8db556
Compare
|
Pushed |
530a604 to
7c7e47b
Compare
c8db556 to
5367189
Compare
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
|
Codex review: needs real behavior proof before merge. What this changesAdds Labs-gated account actions, remote-access setup, recovery-kit saving, browser approval, device management, and an Access page. Example: An owner invites [email protected] as an operator.
Review scores
ProductKind: Feature · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Blocked before merge - 3 items remain This PR completes useful, maintainer-directed UI for the merged OpenClaw ID foundations; the previous name-check finding is fixed, and no new discrete correctness defect was established. Priority: P2 Before merge
FindingsNone. Tests
Agent review detailsHow this fits togetherThe Control UI and bundled Access plugin turn owner actions into browser-signed requests; the existing Gateway membership authority decides admission and enforces removal. flowchart LR
Owner[Owner browser] --> UI[Account menu and dialogs]
Owner --> Access[Access plugin]
UI --> Keys[Browser owner keys]
Access --> Keys
Keys --> Gateway[Gateway membership authority]
Gateway --> Discovery[Discovery mailbox and publication]
Gateway --> Tunnel[Tunnel admission]
Technical reviewBest possible solution: Complete the Labs-gated UI over the existing Gateway authority while preserving browser-held keys and feature-off behavior. Do we have a high-confidence way to reproduce the issue? This is a feature addition; current main contains the Gateway foundations but lacks these Control UI surfaces. Is this the best way to solve the issue? The UI adapters and bundled Access plugin appropriately reuse the existing membership authority; the simplification pass found no concrete need for replacement architecture. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against e27b909e49d3. Merge-risk optionsMaintainer options:
Provenance checked
TestingProof path: shipped entry point. SecurityNeeds attention: No concrete authorization bypass was established, but local-approver final-effect coverage remains incomplete. EvidenceWhat I checked:
Likely related people:
PR surfacePR surface statistics unavailable: the file list is incomplete. 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. LabelsLabel changes: No label changes. Label justifications:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
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 HistoryReview history (9 earlier review cycles; latest 8 shown)
Reviewed November 6, 2026, 1:48 PM ET / 18:48 UTC (Revision 10). |
5367189 to
a93e0c5
Compare
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
|
Merged via explicitly authorized admin squash with attributed pre-existing CI failures.
|
What Problem This Solves
With the Gateway parts in place, an owner still needs a way to use OpenClaw ID from the Control UI: sign in, turn on remote access for a claw, keep the recovery kit, approve their other browsers, and invite and manage people. This PR adds those Control UI surfaces and the bundled Access plugin.
User Impact
No user-visible change while the
gateway.openclawId.enabledLabs switch is off (the default): the account menu, dialogs, the Labs entry's dependent surfaces, thegateway.openclawIdsettings, the Access page and its plugin catalog entry, grants and asset routes are all absent.With the switch on, owners get:
openclaw-id-accessplugin, under Pages, titled Remote access): who may reach this claw through OpenClaw ID. Its People section invites by email, approves or denies requests, shows members' devices and activity, and removes members. A one-line pointer sends readers to Settings → Devices for devices paired with the Gateway.There is no owner reset in this version; the docs say so.
Why This Change Was Made
Builds on the Gateway core PR (#192335) and the tunnel and sign-in PR (#192345), both merged. It is the last PR of the Gateway split of the OpenClaw ID stack.
ui/src/lib/openclaw-id/**: browser-side account storage and sign-in popup, link ceremony steps, recovery-kit export, owner device keys (non-extractable WebCrypto Ed25519 in IndexedDB), owner-approval SAS, device mail and remote sign-out.ui/src/components/openclaw-id/**: the account menu, Make reachable, recovery kit, owner approval and Your devices dialogs, with the Control UI's existing menu and modal components.app-sidebar-identity-menu.tsx), the Labs registry entry, andgateway.openclawIdhidden from settings search and the config form while the switch is off.extensions/openclaw-id-access/**: the Access page (display name "OpenClaw ID remote access"), a bundled plugin enabled by default whose Control UI module loads only while the switch is on.data-openclaw-id-enabledattribute only when the switch is on; the plugin catalog, tab grants, asset routes and managed-plugin list hideopenclaw-id-accesswhile it is off, and a switch change broadcastsplugins.controlUi.changed.@1password/save-button1.3.0 inui(the recovery kit's Save in 1Password button).docs/.generated/config-baseline.counts.json). Thegateway.openclawIdcore keys landed with the earlier PRs.docs/concepts/experimental-features.md(OpenClaw ID remote access) and the plugin reference and inventory.Notes for review
main's fix that keeps the profile avatar element stable (fix(ui): phone account menu truncates Help, blanks the avatar and scrolls #189747). The OpenClaw ID initial is rendered inside that stable avatar instead of replacing it.// SAFETY:comments or were removed (stepOfKindin the Make reachable dialog, the role select on the Access page).Review
An independent review (GPT-6 Astra) found three issues; all are fixed here:
link.test.ts).gateway.openclawIdsettings even with the switch on, because it filtered the schema a second time without the flag.Later changes on this branch:
people-error.test.tsbuilds its credentialed-URL fixture at runtime (new URLwithusername/password), so the diff holds nouser:password@literal for secret scanners. The test still checks that such a URL is stripped from diagnostics.docs/concepts/experimental-features.md:clientIdis listed with the settings needed to turn on remote access, not as optional. The account menu offers Turn on remote access only after OpenClaw ID sign-in, which needsclientId(ClawSweeper P3).Access page actions reach the Gateway authority from feat(openclaw-id): add Gateway membership authority and publication behind the Labs flag #192335, which decides access; the page grants nothing itself. Invites must be signed by a current owner device (
service.invites.test.ts: registration is refused over the mailbox or from an unidentified client);openclawId.peopleand the authority actions refuse viewers, operators, LAN clients and expired owner devices (people-access.test.ts).Rebased onto feat(openclaw-id): add the tunnel transport, OpenClaw ID sign-in and relayed-device Gateway auth #192345 and
mainat258d034391a.maindropped per-row Documentation links from Labs (improve(ui): drop per-row docs links from Labs and config paths from Talk #191418), so the OpenClaw ID Labs row no longer has one and the off-state e2e no longer expects it.Rebased onto
mainat49f8a60f227.mainnow requires an explicit toastseverity(fix(ui): require explicit toast severity #192453), so the OpenClaw ID toasts set one: errors areerror, sign-in and link copy aresuccess, the reachability offer and approval notice areinfo, and partial sign-out iswarning. Labs labels followmain's renames.The raw config editor's schema filter is now a named helper,
omitEditorOwnedConfigLeaves, soconfig/view.tsxstays within the 700-line cap.A second independent review (GPT-6 Astra) found one P1 and three P2s; all are fixed here. Each fix has a regression test, and each test fails with its fix reverted:
make-reachable-dialog.tsx).make-reachable-dialog.tsx,device-key.ts).completeevent, so an aborted write is reported as a failure (device-key.ts).feature-lifetime.ts).Repository guards found three more issues, also fixed: sign-in and recovery-kit print windows now open through the Control UI's opener-free window helpers, the owner-approval handoff is typed as JSON instead of using a chained type assertion, and a device-key test mock documents why it does not keep the module's real exports.
SettingsRow's styles load only with the Settings pages, and the dialog opens from the account menu on any page. The dialog now imports them (make-reachable-dialog.tsx).mainat5310c71fb32(now9977465), becausemainchanged the config baseline and the PR conflicted on its generated hash file. That hash was regenerated; every other file's change is unchanged.9977465, first pushed as761915c, at Josh's request): the sidebar entry is Access, and the page title and heading are Remote access. The page and route id is nowaccess(plugin?plugin=openclaw-id-access&id=access) and the plugin display name is "OpenClaw ID remote access". Nodes will join this page, the sidebar already has Users, and chat details already has a People section. Invites, approvals and members stay under a People section heading. The plugin idopenclaw-id-accessand theopenclawId.peopleRPC are unchanged. Labs copy, docs, the plugin inventory and reference page, config-baseline hashes and tests follow the rename. Checks on the Studio: the Access plugin tests, the OpenClaw ID UI tests, the Labs-off and account-menu e2e suites,tsgo:ui,tsgo:test:ui,tsgo:extensions, changed-file oxlint and oxfmt,lint:ui:i18n,check:docs, the plugin inventory check andconfig:docs:checkall pass. The test-line allocation is now 3,662.0080431:docs/concepts/experimental-features.mdhad two "OpenClaw ID remote access" headings, because feat(openclaw-id): add Gateway membership authority and publication behind the Labs flag #192335 had added a short section. This PR's section now carries that section's off-state and configuration-key details, and the page has one heading. The plugin inventory and reference index now count the bundledopenclaw-id-accessplugin.mainat2394bff0c01after feat(openclaw-id): add the tunnel transport, OpenClaw ID sign-in and relayed-device Gateway auth #192345 merged (59b8a114bf6). Only the generated files conflicted: the config baseline counts and hashes and the Control UI raw-copy baseline were regenerated on the new base. Every other file's change is identical to the previous head (8f6b458).mainat0a6590652dc(head9cbe690). Earlier, only the performance budgets conflicted, becausemainlowered its boot JS ceilings (improve(ui): stop loading unused CJK tables during boot #194241); the budgets below are measured on the current base.typescript(unbound-method)rule flaggeddevice-key.test.ts; the test now calls the realIDBObjectStore.addthroughReflect. The Control UI performance check found larger Chat and New Session boot graphs:config-sections.tsis in them, and its newvisibleConfigSchemahelper importedview-schema.tsx, which pulled the config form analyzer into boot (+6 KiB gzip and two more Chat requests). The helper now lives inconfig-page-state.ts, which only Settings loads.mainat0a6590652dcalready exceeds its own Chat, New Session and largest-chunk ceilings. On it, this branch measures Chat boot JS at 1,288,774 B, New Session boot JS at 797,124 B (Linux CI) and the largest shared chunk at 560,277 B gzip; those ceilings are now the measurement plus 256 B formain's concurrent growth. Total CSS measures 325,045 B gzip / 1,675,690 B raw; its ceilings are the measurement plus 64 B. What this PR adds is the lazy OpenClaw ID sidebar mounts, the sign-in callback check inmain.tsand the account menu styles. Request counts stay within their existing limits.owner-devices-dialog.test.tsx; the test fails with the fix reverted).make-reachable-dialog.test.tsxexpects thecheck_namerequest and fails without the fix).kit-export.test.tsonly repeated the helper's text and is removed (ClawSweeper);recoveryKitLinesis now module-private and its Knip entry is gone.Live proof on a staging Gateway
The studio lab Gateway, one of the four testnet Gateways, runs this PR's head
9977465against staging Discovery and the claw loader onmain's protocol (discovery#4 and claw-loader#4, then their #5 preview-access changes). The later commits (from the lint fix to608a551) change tests, the config page's import graph, one confirmation string, the initial name check and the performance budgets; none touches the Access page's signing or the Gateway. Hostnames, invite secrets and the request location are redacted.openclaw doctor --fixmigrated it from v39. Afterwards the claw's link, root, owner devices with their approvers, members and invites matched a copy taken before the upgrade, and the new Discovery accepted its snapshot withprotocols{"statement":[1],"descriptor":[1]}.add) admitted the member, who reached the Control UI 5 s later. Remove closed the member's tunnel connection.GET /_openclaw-id/v1/membershipreturned 403not_owner_device;POST /_openclaw-id/v1/statementswith anadd_owner_devicechange signed by the member's own key returned 403not_an_owner. The seq did not change.not_an_owner, for the invite and for the change; S3's invite had been accepted before it expired. After every refusal the seq, owner devices and invites were unchanged.Access page: a pending request with Approve and Deny.
After Approve: the member is listed with Remove.
Approving a new browser: the code the owner compares (claw loader).
Your devices: the removal preview. Taken at
9977465, before the copy fix above, so it still says "This browser loses access now".A removed browser is refused.
Evidence
608a551, on a macOS arm64 host through Crabbox: the OpenClaw ID UI tests (17 files),pnpm tsgo:ui,tsgo:test:ui, changed-file oxlint and oxfmt andpnpm deadcode:exportspass, and the name-check test fails with its fix reverted. On8751edc,pnpm ui:check-performance:base fc53c551f5emeasured the budgets above. On the same commits rebased on6f3cd220d44: the OpenClaw ID UI and config page tests (74 files), the Labs-off and account-menu e2e suites,pnpm tsgo:ui,tsgo:test:ui, changed-file oxlint and oxfmt,lint:ui:i18n,ui:i18n:verify,config:docs:check,check:docs, the plugin inventory check, mock exports, the performance script tests and the base performance check pass. With the Your devices copy fix reverted, its test fails.0080431, on the same host:pnpm check:docs(formatting, markdownlint, MDX, links, config examples) and the plugin inventory check pass.25d1354(the styles fix above), on the same host: the Labs-off and account-menu e2e suites, the OpenClaw ID dialog tests andpnpm tsgo:uipass.3da34a9, on a macOS arm64 host through Crabbox: the OpenClaw ID UI tests (18 files), the Access plugin and the Gateway Control UI bootstrap, document and plugin-asset tests pass.pnpm tsgo:ui,tsgo:test:uiandtsgo:corepass, as do oxlint and oxfmt on the 108 changed code files, the mock-export, raw-window.open, chained-assertion, Control UI i18n, config-docs, unused-export and Madge checks. On the previous head, each of the four review fixes above was reverted in turn and its regression test failed.pnpm testover the 34 test files this PR adds or changes (UI unit, browser and e2e suites, the People plugin, and the Gateway Control UI bootstrap, document and plugin-asset tests): 37 files, 316 tests passed (withmanagement-service.test.ts).openclaw-id-off.e2e.test.tsdrives the built Control UI in Chromium with the switch absent and with itfalse. Across the shell, Pages, the account menu, Settings, Labs and the command palette it finds no OpenClaw ID copy or elements, loads no OpenClaw ID, recovery-kit or 1Password assets, and sends no config writes or chat requests; an unsent draft survives;control-ui-plugin-assets.test.tschecks that the plugin catalog, grants and asset routes disappear at once when the switch turns off; the bootstrap tests check the document attribute is absent.pnpm tsgo:core,pnpm tsgo:uiandpnpm tsgo:extensionspassed.pnpm ui:i18n:verifypassed after regenerating the raw-copy baseline (two recovery-kit strings).pnpm check:changed: see the comment below for the run on the published head.config/test-lines-allocations/openclaw-id-ui-people.txtallocates exactly the 3,667 test lines this PR adds (new tests for new surface).CI failures inherited from
mainThese fail on
mainitself and are not caused by this PR (which touches none of the inputs):deep-researchplugin build. Onmain,extensions/deep-research/browser/index.tsxandpane.tsximport./client.js, which097f990("retire unused research browser client") deleted before feat(research): add native session research pane #177232 added the imports. The plugin asset build,tsgo:extensionsand the deep-research e2e fail withCould not resolve "./client.js"/TS2307:build-artifacts,check-prod-types,checks-node-changed,checks-node-changed-compact-small-*,checks-ui-e2e(deep-research shard) and PostgreSQL conformance (its build step).mainat0a6590652dcalone reportsover by: 52; net delta: 0. Tree is over the ceiling; this change does not add test lines(main's CI skips this job). This PR's allocation equals the test lines it adds.chat-goal-replace.e2e.test.tsfails onmain0a6590652dcon a macOS arm64 host as well.chat-composer-overflow.browser.test.tsx,chat-composer-display-snapshot.e2e.test.tsandsettings-layout.e2e.test.tsfailed in CI; all three pass on bothmainand this branch on a macOS arm64 host, andmainfixed the settings-layout locator in fix(ui): update agent menu title selector in layout test #194277.control-ui-performancewas this PR's and is fixed by the approved budgets above.Screenshots
Taken from the built Control UI in Chromium on a macOS arm64 host, with a mocked Gateway and a synthetic account (
[email protected],claws.example.test). The menu shots are from3da34a9; the Turn on remote access shots include the styles fix in25d1354.Before: Labs switch off (the default). The account menu has no OpenClaw ID section;
openclaw-id-off.e2e.test.tschecks this across the shell.After: switch on, signed out, then signed in on this computer.
Turn on remote access, name step (light and dark).
Remote access on: desktop (dark) and phone width.
Not shown here: the recovery kit step (it displays a generated secret). The Access page, approval and Your devices are in the live proof above.