Repository navigation
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. |
|
Codex review: needs maintainer review before merge. Reviewed October 2, 2026, 10:31 PM ET / October 3, 2026, 02:31 UTC (Revision 23). ClawSweeper reviewWhat this changesPreserves trusted-proxy authentication during onboarding reruns and carries local passwords through setup checks, recovery, and terminal handoff. Merge readiness✅ Ready for maintainer review This remains a necessary, proof-backed fix. Current main and the latest release retain the reported defect; the prior findings and remaining proof requests are resolved, with no new blocking finding. Priority: P1 Review scores
Verification
How this fits togetherOnboarding converts existing Gateway configuration and operator choices into saved settings. Completion then authenticates local health checks and connects the terminal client to that Gateway. flowchart TD
A[Existing Gateway settings] --> C[Onboarding configuration]
B[Explicit operator choices] --> C
C --> D[Preserved authentication policy]
D --> E[Local credential resolution]
E --> F[Selected loopback Gateway]
F --> G[Health results and terminal handoff]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource +97, Tests +1001, Docs +2. Total +1100 across 28 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. Technical reviewBest possible solution: Keep the existing proxy policy authoritative and use the existing credential and connection owners for all same-host setup checks. Do we have a high-confidence way to reproduce the issue? Yes, from source: rerunning classic onboarding with stored trusted-proxy auth reaches main's token/password-only inference and writes a replacement mode. No target code was executed during this read-only review. Is this the best way to solve the issue? Yes. Preserving the authored mode and reusing existing secret resolution and local-target binding repairs the defect without adding configuration or changing Gateway authorization rules. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against ac96ec93fa95. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (22 earlier review cycles; latest 8 shown)
|
52bdbd1 to
43bbc50
Compare
|
@clawsweeper re-review Addressed the review on the new head
|
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
43bbc50 to
824d03b
Compare
|
@clawsweeper re-review Addressed the new P1 on head P1 — Tailscale Serve with preserved Fix mirrors the non-interactive owner ( Two regression tests were added in Suite totals on the two touched suites moved from 10 failed / 26 passed (unfixed main) to 7 failed / 31 passed; all three new |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
824d03b to
104c955
Compare
|
@clawsweeper re-review Addressed all three findings on head [P1] Non-loopback bind with preserved [P2] Trusted-proxy local password through finalization. Password resolution now also runs for [P3] Token completion guidance. The probe-success note is gated to token mode; preserved modes keep the dashboard hint and no longer claim a stored token or suggest Verification. Five added |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
Use the real asynchronous Tailscale lookup contract so the negative control reaches the Gateway auth assertions. Cover selected bind preservation, loopback probe targets for specific interfaces, and the existing none-mode credential inference before applying the production corrections. Co-authored-by: wangmiao0668000666 <[email protected]>
Preserve trusted-proxy auth in both onboarding writers and apply configure's incompatible-exposure rule before changing the selected mode or bind. Forward local passwords through the existing noninteractive and foreground probe paths, and keep co-located probes on the required loopback listener. Keep CLI auth choices narrow, restore the existing none-mode inference, consolidate finalization password handling, and document rerun behavior. Retain contributor credit and existing secret/config persistence owners. The approved conversational CLI recovery path has an additional regression checkpoint in this commit; its call-site repair follows isolated negative CI proof before landing. Co-authored-by: wangmiao0668000666 <[email protected]>
Reuse onboarding's local-password resolver for approved conversational CLI recovery, preserving configured values and SecretRefs before ambient fallback. The three credential regressions failed on d7591dd in isolated CI. Add negative checks for the remaining health-RPC target binding: post-setup health must use the selected local Gateway port, so ambient CLI overrides cannot redirect the derived local credential. The existing Gateway call API already owns this binding; its caller fix follows this checkpoint. Co-authored-by: wangmiao0668000666 <[email protected]>
Bind post-setup health RPCs to the selected port so ambient gateway URL or port overrides cannot redirect derived local credentials. Co-authored-by: wangmiao0668000666 <[email protected]>
|
@clawsweeper re-review Final candidate: f2f9419. The maintainer follow-ups cover sibling Funnel auth preservation, local password/SecretRef propagation, conversational CLI recovery, and local health-target binding. Independent Codex review is clean through P2. Final secretless CI: https://github.com/openclaw/openclaw/actions/runs/37087800509 The PR body records the negative regression runs and historical single-file timing evidence requested by the earlier review, with measurement limits stated. |
|
🦞👀 Re-review progress:
|
|
A note on the last few hours from the contributor side: I was actively working through the Revision 18 items in parallel — I had the none-mode inference restore, the loopback probe normalization, the non-interactive Funnel refusal, and the probe-password forwarding implemented locally, and then the CLI-recovery probe auth and the health-RPC port binding as follow-ups. Both times my pushes raced with yours landing the same fixes minutes earlier, so I happily dropped mine. Thank you for driving this to completion — and for the co-author credit. Studying your versions against mine was genuinely instructive:
I'll keep watching CI and the next review round, and I'm happy to pick up anything you'd rather leave with me — including the PR body updates once the scope settles. |
…teway Exercise classic and noninteractive health through the real health command and isolated Gateway process with trusted-proxy password auth. Both ambient URL-plus-port and port-only overrides point at an unrelated loopback listener; require successful intended health RPCs and zero unrelated connections. Keep existing minimal-fixture logs unchanged outside configured-auth proof and preserve contributor attribution. Co-authored-by: wangmiao0668000666 <[email protected]>
|
@clawsweeper re-review Final candidate fd14605 passed secretless CI: https://github.com/openclaw/openclaw/actions/runs/37089103100 The PR body now includes the requested production-path final-effect proof. Classic and noninteractive setup each ran the real health command/client against a real trusted-proxy Gateway process. For both URL-plus-port and port-only ambient overrides, each scenario recorded two intended health RPCs and zero unrelated listener connections, and required successful real health completion. Exact job links and all four synthetic result rows are in the body, along with measured costs for every changed test suite and their measurement limits. No production code changed after the previously reviewed fix. |
|
🦞👀 Re-review progress:
|
|
Merged via squash.
|
Closes #150083.
What Problem This Solves
Fixes: rerunning onboarding silently replaces an existing trusted-proxy Gateway authentication policy.
User Impact
Existing proxy Gateways keep their auth mode, proxy policy, and password SecretRefs through setup. Explicit auth choices remain available. Selecting Funnel while retaining trusted-proxy auth requires an explicit switch to password mode or leaving Funnel off.
Why This Change Was Made
Wizard settings carry the config owner's auth modes while CLI auth choices remain token/password. Existing
nonecredential inference stays unchanged. The noninteractive writer rejects the same Funnel downgrade, and configure disables incompatible Tailscale exposure before changing the selected bind or auth mode.Completion and conversational CLI recovery use the existing local-password resolver, including SecretRefs and ambient fallback. Same-host probes and terminal handoff use the required loopback listener, including for custom and tailnet binds. Post-setup health RPCs pin the configured local port so ambient Gateway URL/port overrides cannot redirect derived credentials.
Gateway authorization rules and persistence owners stay unchanged; no SQL or schema changes are introduced. The production delta is +92 lines (176 added / 84 removed); tests and test support are +1006, docs +2. The growth supplies the missing auth-mode and credential handling; duplicate branches were consolidated. No changelog edit: release-note context is retained here.
Evidence
Production candidate
f2f941971cfd9a45c9d3189ee1189de415764c22passed secretless CI 37087800509, including the changed test lanes, types, lint, security and UI/Gateway checks. Independent Codex autoreview completed with no actionable P0–P2 findings. No contributor code was executed on the maintainer host.Final candidate:
fd14605e68e2594283de42775b8a382513b06b86. The complete final candidate passed secretless CI 37089103100. The full candidate passed independent review through P2 before publication.Production-path credential destination proof used the real health command, real Gateway client and real isolated Gateway process with trusted-proxy password auth. Only surrounding UI/service setup is stubbed. Both callers require the real health command to complete successfully, then inspect the child Gateway's health-request log and an independently listening unrelated socket. Maintainer verification: I downloaded and inspected both exact-head job logs, verified all four records against the passing tests, and accept this scoped credential-destination proof. CI observed:
Exact-head logs: classic / wizard and noninteractive. The proof logs contain only synthetic method/count observations, no credentials or private endpoints. This addresses the previous review's final-effect proof request without changing production code.
Measured changed-suite costs on that same run (sum of Vitest's printed test-case milliseconds; not per-file wall time or standalone single-worker measurements):
src/wizard/setup.gateway-config.test.tssrc/wizard/setup.finalize.test.tssrc/wizard/setup.finalize.trusted-proxy.test.tssrc/wizard/setup.model-auth.test.tssrc/commands/configure.gateway.test.tssrc/commands/onboard-helpers.test.tssrc/commands/onboard-non-interactive/local/gateway-config.test.tssrc/commands/onboard-non-interactive.gateway-health-auth.test.tssrc/commands/onboard-quickstart-host.test.tssrc/system-agent/setup-apply.test.tsThe new real-Gateway cases took 4,956 ms (classic) and 3,486 ms (noninteractive), including fixture startup and cleanup inside each test. Historical single-file wrapper wall measurements remain below for comparison; no additional CI reruns were launched merely to obtain standalone timing numbers.
Regression proof in secretless PR CI:
c65204e5cd11d: eight intended assertion failures for both Funnel mode rewrites, configure bind preservation, two omitted-password paths, custom/tailnet probe targets, andnonecredential inference. The earlier configure fixture Promise-contract error was corrected before this run.d7591dd5515ec: those repairs passed; only the three new conversational CLI recovery credential cases failed.6173931727ec3: conversational recovery passed; only three new health-call target-binding assertions failed. Commitf2f941971cfd9supplies the existing local-port override at both call sites.The contributor's real Gateway/PTY evidence covers original config preservation, local password authentication, and terminal handoff. Final classic/noninteractive credential routing additionally has the real-Gateway CI proof above; conversational recovery and the other sibling paths have isolated boundary coverage. No production Gateway or external credentials were used.
Historical test-cost evidence at
c65204e5cd11d: trusted-proxy finalization's four tests took 6.05 seconds wrapper wall time; Gateway configuration's 18 tests took 5.49 seconds. These were CI single-file invocations with inner parallelism 1, not separate standalone--maxWorkers=1measurements.Credit to @wangmiao0668000666 for the original fix. Their commits are retained, and maintainer follow-ups include their verified human co-author attribution.