Repository navigation
feat(auth): use personal Tailscale identity in Companion - #1989
TheAngryPit wants to merge 9 commits into
Conversation
Verify the canonical personal profile on the current Gateway connection before enabling operator features. Keep native Dashboard proof bound to that lease, retire private browser profiles on close, and retain existing credential authentication.
|
🦞👀 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. |
|
Codex review: needs real behavior proof before merge. What this changesAdds per-Gateway personal Tailscale authentication for Companion chat and an embedded Dashboard. Example: Connect to wss://node.example.ts.net using Personal Tailscale identity.
Review scores
ProductKind: Feature · Worth it: Needs a maintainer decision · Fix scope: Complete Merge readiness⛔ Blocked before merge - 3 items remain Keep this PR open: personal authentication remains absent from main, and the contribution is distinct; the existing recovery finding remains unresolved. Priority: P2 Decision needed
Before merge
Findings
Tests
Agent review detailsHow this fits togetherThe connection manager turns saved Gateway settings into authenticated operator connections and supplies verified identity to native chat and the Dashboard signing bridge. flowchart LR
A[Saved Gateway settings] --> B[Credential resolver]
B --> C[Connection manager]
C --> D[Verified operator identity]
D --> E[Native chat]
D --> F[Dashboard signing bridge]
F --> G[Gateway Dashboard]
Technical reviewBest possible solution: Keep the existing connection and Dashboard owners, complete typed personal recovery, and ship the opt-in mode against an agreed public producer contract. Do we have a high-confidence way to reproduce the issue? Source establishes both the missing main capability and the rejected-hello recovery defect; the existing protocol test supplies wrong-method and empty-scope inputs, but no target code was executed in this review. Is this the best way to solve the issue? The registry, credential resolver, connection manager and Dashboard launcher are appropriate existing owners; the smallest repair routes rejected personal hello metadata through the typed native recovery path already added. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 0bd934818151. Merge-risk optionsMaintainer options:
Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Likely related people:
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:
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 (2 earlier review cycles)
Reviewed November 12, 2026, 11:26 AM ET / 16:26 UTC (Revision 3). |
PR cleanup reviewReviewed head: Personal authentication is still absent from main, so this is not a superseded change. The updated head improves same-person and media fencing, but the core Control UI dependency remains open and live end-to-end authority proof is explicitly incomplete. The English rejection/revocation strings still reach the WinUI error display directly. Keep this draft for localization, compatible-release agreement, current-main reconciliation and independent security/runtime qualification. Action in this cleanup pass: leaving this PR open. No branch changes or runtime-proof waiver. The findings above come from source, discussion and recorded-CI review; Windows validation was not rerun in this pass. |
|
Note 🤖 Codex responding on behalf of TheAngryPit Actual Windows acceptance now covers personal Chat, embedded Dashboard admission, device revocation after signing, and stored-data compatibility at
Runtime provenance: existing custom Windows/WSL daily Core Remaining limits: initial unapproved-device admission also returned Current-head canonical CI 43213859705 failed three tests: |
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
Related: #1117. Depends on openclaw/openclaw#163765 for the personal-identity Control UI contract. Separate from the managed Gateway upgrade in #1128.
What Problem This Solves
Companion users need an explicit way to use their verified Tailscale identity instead of shared Gateway credentials.
User Impact
Users can select personal Tailscale identity for a supported secure Tailscale Serve Gateway. Personal sign-in verifies a non-shared profile and never falls back to Shared owner after a failure. Existing shared-credential connections and Windows node identity remain available through their existing owners.
The saved-row Open dashboard action also respects Personal mode. It requires that the requested Gateway is currently admitted; an inactive or unverified Personal row refuses the launch and asks the user to reconnect. It does not silently switch the selected Gateway or use a retained shared token.
Why This Change Was Made
The operator connection verifies the person before exposing Chat and Dashboard. Native Dashboard proofs stay bound to the selected Gateway, verified person, device, recovery scope and connection generation. Reconnection, profile changes and selection changes retire the previous authority. The branch is reconciled with canonical Windows main while retaining current request cancellation, search, keepalive and setup dispatch checks.
This PR covers the Serve route. LocalPrimary personal identity is not included: it needs a separate public Core producer for signed bind/use and a corresponding Windows follow-up. This PR does not configure a Gateway or automatically migrate existing profiles.
Evidence
Main reconciliation — 12 November 2026
Published head
70eb8a8f7b3fe4489637b09144f5fe14e78859eais an ordinary merge ofc43d070bea087ef940d40571855e41715b0d3aacand public main0bd934818151c39890aa13d3ebed5e5dc4f7f9fb, with tree838e8807c49903859b28837fd4cb5badcf24a9d3. The six resource append conflicts retain both the personal-identity guidance and main's tool-details panel strings. XML parsing, uniqueness and independent parent-value comparisons passed across all six locales; main's intentional removal of an obsolete compatibility label is retained.The exact staged merge tree was built and tested before creating the merge commit: official build and native UI assembly compilation passed; Tray 6,371 passed; localization 41 passed; personal manager/policy 23 passed. Shared had 5,847 passed, 30 skipped and the same 12 missing-privilege failures, with no additional failed names. The conflict-resolution P0–P3 review completed 17/17 passes without findings; independent TestAudit and named NoComments accepted this resolution scope.
The new canonical CI run is in progress; it is not claimed green. This resource reconciliation includes no new live-Gateway/native UI interaction run. The earlier runtime proofs and remaining person/app-role, public Core dependency and release-qualification limits below retain their stated commits and boundaries.
Earlier implementation and runtime evidence
Follow-up
500a5752773a2a8e20a58a08810613ea57870c8a(treebd852533143b6f2b7f26d9ad82141666a2015c0d) fixes the private WebView2 profile-close lifecycle exposed by the preceding head's native CI. Closing now awaitsProfile.Deleted, rather than accepting a dispatcher drain as equivalent acknowledgement. The original native test independently observes that event and requires it beforeCloseAsyncreturns, retaining its existing ten-second bound. This acknowledges profile closure, not physical directory deletion.Canonical Build/Test on 500a executed the original private-profile test successfully (2.319s) and the stale/current native-bridge reply test successfully (8.752s); the complete native Tray UI suite passed 1,344 cases with nine not executed. The tested merge contained the exact repaired source blobs. This demonstrates the profile-close acknowledgement repair on native CI, not physical directory deletion. The overall run still failed two Mock Gateway cases: UsageHero could not locate its target beyond the ten-row preview; UsagePinned failed an earlier ChatComposerInput lookup. Neither is described as a product-layout repair.
Earlier head
c43d070bea087ef940d40571855e41715b0d3aaccarries that UsageHero setup correction and failure-only diagnostics for the unresolved UsagePinned lookup. It also routes personal verification and revalidation failures through typed, localized native guidance, preserving the attempted failure kind across rollback and distinguishing incomplete recovery. Six locales are included. This changes presentation without granting authority or adding credential fallback.On production tree
2187ef19ba421bfbaa3e951d1258adcd37671cbb(commit9596629bf683678ebd156dbec90d7a055374b588), the official product build and native UI test assembly compilation passed; Tray passed 6,329 with zero skips, and Shared passed 5,843 with 30 skipped and the same 12 host symlink-privilege failures. Real manager/rollback/presentation regressions have RED/GREEN evidence (23 manager/policy cases and six rollback/presentation cases pass). Independent P0–P3 review completed all 31 passes with no findings; TestAudit accepted the separate producer, rollback and presentation contracts. Named NoComments accepted the final source including its required new-module documentation. Final treeadeb18cde65d4ca1d73e81d4a8d2cd34ae7d3ff6differs only by six helper documentation lines; that delta received a separate scoped-clean P0–P3 review and successful documentation/prerequisite checks. No product suite was rerun or claimed for the comment-only delta. Earlier-head canonical CI 43213859705 failed three tests:Automations_ScopesToAgentsAndCoversMainStates(Dark),SessionsDesignNativeWindowGallery, andNativePagesAndOwnerLinks_StayInOneWorkspaceWindow(Dark). These remain unresolved current-head failures; no inherited/flaky classification is asserted. Rendered localization qualification remains incomplete. Compilation and static review are not presented as native UI proof.Commit
36b8090527fbe9bbfd08ec96747ef35c96e5017aintegrates published32e59cbef166a3b2e5b8ecd8b0d889f19be5c424with pinned canonical Windows main3f47e83888db83740660d03c3ecd403550235187, the saved-row repair and bounded error-reply diagnostics. Its tested tree is5bd0937fca4266fcf4424c1dfb32d782f467b1a5, with 62 changed paths relative to that canonical base. No private runtime composition or unrelated personal patches are included.The shared-token regression exercises the real replacement connect over the Gateway fixture, after an empty request ledger is observed under the transition semaphore. It checks the actual rejected replacement request and preservation of the durable device token. The initial mock lifecycle does not send a wire connect.
Change Type
Scope
winnodeRequired proof pools
windows-winui-interactive: native connection selection and personal Dashboard behavior.windows-wsl-gateway-e2e: pairing, recovery and real Gateway identity behavior.Validation
The final required build/Shared/Tray closeout ran on tree
5bd0937fca4266fcf4424c1dfb32d782f467b1a5; earlier owner-specific evidence is identified separately../build.ps1 -Project All -Configuration Debug -NoTrustRepository: all projects passed, including WinUI, on Windows x64. An earlier attempt stopped at prerequisite detection because this harness omitted the native OS/architecture environment. After verifying the actual Windows x64 host and installed Visual Studio VC runtime, normal builds used process-local native OS/architecture values. No dependency or machine policy was changed.dotnet test tests/OpenClaw.Shared.Tests/OpenClaw.Shared.Tests.csproj --no-restore: 5,843 passed, 30 skipped, 12 failed, total 5,885. All 12 failures are missing host CreateSymbolicLink privilege in three test owners identical to pinned canonical main; exact failure-set comparison matches the preceding repaired-tree run. No permission override, new skip or weakened assertion was used. The 133 affected personal/media/WebSocket/search/startup cases passed with zero skips in the initial integration; those owner sources are unchanged.dotnet test tests/OpenClaw.Tray.Tests/OpenClaw.Tray.Tests.csproj --no-restore: 6,323 passed, zero failed/skipped.604c:dotnet build tests/OpenClaw.Tray.UITests/OpenClaw.Tray.UITests.csproj -p:Platform=x64 -r win-x64passed, zero warnings/errors. Compilation only; native UI tests were not executed. The final delta changes only error-reply diagnostics and comments in the product window.dotnet test tests/OpenClaw.Connection.Tests/OpenClaw.Connection.Tests.csproj --filter 'FullyQualifiedName~GatewayConnectionManagerPersonalIdentityTests|FullyQualifiedName~GatewayPersonalAuthenticationPolicyTests|FullyQualifiedName~CredentialResolverTests|FullyQualifiedName~ConnectWithSharedTokenAsync_RevalidatesDurableTokensUnderTransitionSemaphore': 56 passed, zero failed/skipped, 553ms. The UI-only repair does not change these owner or fixture sources.scoped-clean, no actionable, filtered or rejected findings. This supplements the original full review and its explicit finding dispositions.Real Behavior Proof
c43d070bea087ef940d40571855e41715b0d3aac; Companion executable SHA256A52ACB508281C3067EC2000F390F35081E9B1D5BF7E2C10B6BBD20F04E248F78.0f6610ca2777edb870fa5fee1d04a3884bcceb4a, version2026.11.3, entry SHA256d602c263712830450271ccba9552a9c6d5ddf55eec8091ea03f4f7ad0fe73e24. This demonstrates that runtime composition, not a verbatim shipping release of the unmerged public dependency.users.selfprofile.sessions.messages.subscriberesult, and rendered its marker.NOT_PAIRED / PAIRING_REQUIREDwithin 3.813 seconds (native validity window 120 seconds). No protected mutation was sent; independent task-label readback was unchanged. This negative test uses the real manager/bridge and Gateway, not an automated embedded-WebView revocation journey.Earlier-head canonical CI 43213859705 failed three tests:
Automations_ScopesToAgentsAndCoversMainStates(Dark),SessionsDesignNativeWindowGallery, andNativePagesAndOwnerLinks_StayInOneWorkspaceWindow(Dark). These remain unresolved current-head failures; no inherited/flaky classification is asserted.Ready for Review denotes GitHub review state, not merge readiness or completed end-to-end qualification.
Security Impact
Compatibility and Migration
Review Conversations
I replied to or resolved every bot review conversation addressed by this PR.
I left unresolved only conversations that still need maintainer judgment.
Review conversations and hosted checks must be assessed on the final pushed head; no CI dispatch is presented as a completed build or review.
Latest-main refresh — 21 November 2026
This branch now merges Windows main
794f530aa933de07b1b2bd618c0ac6e9d3d74a4band preserves this PR's opt-in personal Tailscale operator mode. Conflict resolution retained current main window-visibility and UI-wait contracts, the PR's Dashboard admission path, lease fencing and file-media content-type handling, and both main's resource updates and the six localized personal-auth resource sets.The hello-ok rejection path now raises typed
PersonalIdentityUnverifiedbefore the legacy authentication notification when the Gateway returns the wrong auth method or a missing/blank recovery scope. The existing protocol fixture now asserts that typed failure for those inputs. The challenge parser's public contract is documented.Focused current-source checks passed:
PersonalTailscaleGatewayClientTests: 9 passed.GatewayConnectionManagerPersonalIdentityTests: 10 passed.ConnectionPagePersonalIdentityTestsandGatewayDirectConnectServiceTests: 68 passed.win-x64. The opted-inUsagePinned_ToggleOwnsHitPointAndTabOrderWithVisibleOperationFeedbackUI smoke did not pass: it timed out waiting for the Light theme selector while the fixture app reported responsive. This is not a personal-auth journey and is not claimed green.No live personal sign-in replay was performed in this refresh. Existing recorded runtime evidence above retains its original revision and environment boundaries. Hosted CI for this head is pending.