Repository navigation
fix(minimal): stop claiming a box name opens in any browser - #2211
Conversation
With native DNS deployed, the session-start host line said `names: <box>.min.internal resolves in any browser on this machine`. The name resolves to a reserved local address, but nothing listens there for a browser, so the connection the line promised is refused. The native arm now claims resolution only and names the path that opens the box: the hostname proxy, which keeps serving beside native DNS (NET-019) and routes box names. With no proxy port the line says only that the name resolves on this machine. Updates the host_line doc, the resolver and cli tests that pinned the old words, the CLI reference, and the NET-142 native requirement.
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
Spec lint
Advisory. None of this blocks the merge; the review decides. Advisory, and never a merge gate. Linter: |
|
Approved: no findings at Nothing to do. Clobber: none: |
There was a problem hiding this comment.
correctness
minimal-review — approved
Verdict APPROVE — No findings.
security
minimal-review — approved
Verdict APPROVE — No findings.
supply-chain
minimal-review — approved
Verdict APPROVE — No findings.
Panel: 3 of 3 personas ran (correctness, security, supply-chain).
The e2e asserted the old 'resolves in any browser on this machine' text at the range-step check and the NET-018 activate check; match the new line.
There was a problem hiding this comment.
correctness
minimal-review — approved
Verdict APPROVE — No findings.
security
minimal-review — approved
Verdict APPROVE — No findings.
supply-chain
minimal-review — approved
Verdict APPROVE — No findings.
Panel: 3 of 3 personas ran (correctness, security, supply-chain).
* fix(minimal): stop claiming a box name opens in any browser With native DNS deployed, the session-start host line said `names: <box>.min.internal resolves in any browser on this machine`. The name resolves to a reserved local address, but nothing listens there for a browser, so the connection the line promised is refused. The native arm now claims resolution only and names the path that opens the box: the hostname proxy, which keeps serving beside native DNS (NET-019) and routes box names. With no proxy port the line says only that the name resolves on this machine. Updates the host_line doc, the resolver and cli tests that pinned the old words, the CLI reference, and the NET-142 native requirement. * test(e2e): match the reworded names line in the session e2e The e2e asserted the old 'resolves in any browser on this machine' text at the range-step check and the NET-018 activate check; match the new line. (cherry picked from commit 6fc7894)
What
With native DNS deployed, the session-start host line (
LiveSurface::Nativearm ofhost_line_besideincrates/minimal/src/resolver.rs) now reads:and, when the create reply carries no proxy port,
names: <box>.min.internal resolves on this machine.It was
names: <box>.min.internal resolves in any browser on this machine.Also updated: the
host_linedoc comment, the resolver unit tests and thetests/cli.rsassertion that pinned the old words,
docs/reference/cli-min.md, and the NET-142 nativerequirement in spec 18 that quoted the line.
Why
QA on 0.7.0-rc2 (macOS) found the old line false. The name resolves to a reserved 127.0.64.N
address, but no listener binds that address, and ingress binds only 127.0.0.1:EXT. A browser
that connects to the name gets a refused connection.
The new wording promises resolution only, and names the path that does open the box. The
hostname proxy keeps serving beside native DNS (NET-019) and routes box names:
crates/minimal/src/cmd/session.rs, the surfaceverdict comment: "The proxy keeps serving beside native DNS (NET-019)").
serving_proxy_portcomes from the same create reply and is the port the Proxy arm alreadyprints.
name_surface_reported_when_both_deployedincrates/minimald/src/rpc.rsroutes a box-name request through the proxy after the native verdict, and the
NET-019 test in
crates/minimald/src/net/proxy.rsdoes the same.Left out
QA also saw the native line for
host_ipboxes, whose name answers NOERROR with no records, andfor
noneboxes, whose name answers NXDOMAIN. The network mode is available at the oneproduction call site (
config.networkincmd/session.rs). Using it would need a newhost_line_besideparameter and per-mode wording. Thenonecase needs wording of its own,because the proxy has no route to a box that has no network. That is more than a change to this
line, so this PR leaves it. For those modes the line still says "resolves on this machine". The
proxy half of the line is still true for
host_ipboxes, which the proxy routes as host-netboxes.
Verification
cross test --target aarch64-unknown-linux-musl -p minimal host_line:Full
cross test --target aarch64-unknown-linux-musl -p minimal --no-fail-fast:The two lib failures are
tests::a_stopped_vm_does_not_hold_a_box_name_resolutionandtests::legacy_network_spellings_parse_with_hint. Both fail under cross on every branch and arenot related to this change.
just fmt-checkis clean.just lint-proseshows no new alerts on the changed lines ofdocs/reference/cli-min.md. On the spec requirement line, the only remaining alerts are theEARS sentence-length warning and the
verify:line alerts, which were there before this change.scripts/session-e2e.shpinned the old text in two checks (the range-step check and the NET-018 activate check); they now matchresolves on this machine. The first CI run failednative-daemon-e2eon that pin.