[codex] restore QR bootstrap operator handoff#83684
Conversation
|
Codex review: found issues before merge. Workflow note: Future ClawSweeper reviews update this same comment in place. How this review workflow works
Summary Reproducibility: yes. at source level: current main defines setup-code bootstrap as node-only and the branch adds the operator handoff path and tests around hello-ok.auth.deviceTokens. I did not run a live native QR onboarding repro in this read-only review. PR rating Rank-up moves:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. PR egg What is this egg doing here?
Real behavior proof Risk before merge
Maintainer options:
Next step before merge Security Review findings
Review detailsBest possible solution: Land only after the stale docs are aligned and maintainers explicitly accept the bounded QR operator-token model, ideally with redacted native QR onboarding proof if they want transport-level confirmation. Do we have a high-confidence way to reproduce the issue? Yes at source level: current main defines setup-code bootstrap as node-only and the branch adds the operator handoff path and tests around hello-ok.auth.deviceTokens. I did not run a live native QR onboarding repro in this read-only review. Is this the best way to solve the issue? Not yet. The implementation is in the right gateway/bootstrap seam, but the PR is not merge-ready until the conflicting docs and maintainer security-boundary decision are resolved. Label justifications:
Full review comments:
Overall correctness: patch is incorrect Security concerns:
What I checked:
Likely related people:
Codex review notes: model gpt-5.5, reasoning high; reviewed against 090180123898. |
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Merged via squash.
Thanks @ngutman! |
Summary
operator.approvals,operator.read, andoperator.writeRoot Cause
PR #81292 / commit
b17e77a22bchanged the built-in setup-code bootstrap profile to node-only and removed thehello-ok.auth.deviceTokenshandoff. That reversed the mobile onboarding behavior restored by PR #58382 / commit69fe999373, where iOS and Android suppress the operator loop during bootstrap auth and only start it after persisting an operator token from the trusted bootstrap handoff.Verification
pnpm docs:listgit diff --checknode scripts/run-vitest.mjs src/shared/device-bootstrap-profile.test.ts src/infra/device-bootstrap.test.ts src/infra/device-pairing.test.tsnode scripts/run-vitest.mjs src/gateway/server.auth.control-ui.test.tsswift test --package-path apps/shared/OpenClawKit --filter GatewayNodeSessionTestsCODEX_REVIEW_AUTO_TESTS=0 bash /Users/guti/.codex/skills/codex-review/scripts/codex-review --mode localReal Behavior Proof
Behavior addressed: mobile QR/setup-code onboarding again receives a node token plus a minimally scoped operator token from the trusted bootstrap handoff.
Real environment tested: local Codex worktree on macOS, gateway/bootstrap Vitest suites, shared Swift package tests.
Exact steps or command run after this patch:
node scripts/run-vitest.mjs src/shared/device-bootstrap-profile.test.ts src/infra/device-bootstrap.test.ts src/infra/device-pairing.test.ts;node scripts/run-vitest.mjs src/gateway/server.auth.control-ui.test.ts;swift test --package-path apps/shared/OpenClawKit --filter GatewayNodeSessionTests;git diff --check;pnpm docs:list;codex-review --mode local.Evidence after fix: gateway tests assert
hello-ok.auth.deviceTokensincludes the operator handoff token for QR bootstrap, paired devices have node + operator tokens, allowed operator scopes are bounded, and admin/pairing replay paths still fail.Observed result after fix: focused gateway/bootstrap tests, Swift handoff tests, docs listing, diff check, and codex-review all passed.
What was not tested: Android Gradle unit tests could not start because this worktree has no configured Android SDK location (
ANDROID_HOMEorapps/android/local.properties).