Repository navigation
PASS_WITH_CONDITIONS
Baseline. This re-reviews 15cf4598 against the PASS on 42590fed (this PR), on the same arch commit 7a86ec7b. I checked these facts. since.diff equals git diff 42590fed 15cf4598. pr.diff equals git diff befda07d 15cf4598, and befda07d (#2968) is the merge base. The compare has one merge, 3e3ac088, and one branch commit, 15cf4598. The merge is clean (git diff-tree --cc is empty), so its hunks (boxes/core/egress.rs, mfile, cmd/list.rs, tests.rs, tests/cli.rs, session-e2e.sh, part of create.rs) come from main, and I do not rule on them here. 15cf4598 changes only the comment above ActivationStep::HoldName in crates/minimal/src/cmd/boxes/create.rs.
Governs: specs/networking/deployment-and-egress-gateway.md §7.1 line 265 (the host-side creator decides dynamic ingress, records an ask answer host-side, and audits locally), line 244 (the helper's zone records derive from the records it holds), line 255 (an in-zone name answers NODATA, an unknown name NXDOMAIN).
Ruling. The new comment is accurate. I checked it against the code. min session destroy releases a none box's hold (lifecycle.rs line 247, release_held_box_name). The dashboard's destroy (dash/rpc.rs line 385) and min session rename (cmd/session.rs line 736) test vm_host::holds_name, which is true only for HostNet. So the dashboard leaves a stale hold: the name of a destroyed box stays in the zone and answers NODATA, against line 255. A rename leaves the hold on the old name, so the host's audit record names the box by a name it no longer has, against the exact-record rule for line 265. The PR introduced the none hold, so these gaps are its own, and no issue names them. C1 fixes both with one predicate change. While reading the hold paths I also found that rehold_held_name_before_attach returns early for every mode except HostNet. After a VM host daemon restart, a none box's hold expires at HELD_NAME_RECONFIRM_BOUND, and control.rs no_switch_box_name (line 2845) then refuses the box's report, so the decision is not audited (line 265). C2 fixes it. Both edits are outside the task's layers:, so the change can merge with them open once each is filed as an issue and named in the PR body.
Departure from precedent. The PASS on 42590fed covered the same code. Its comment then said every destroy releases the hold, and that claim was false. The corrected comment brings the two gaps in C1 into view. C2 is code that the compare does not touch. I raise it because it is the same hold model and the same design line. A reviewer on the next head can treat both as new findings, not a change of rule.
Not checked. I did not compile or run any test. I did not check that the dashboard and rename paths have tests that a predicate change will break.
Conditions
- C1:
crates/minimal/src/cmd/boxes/vm_host.rsholds_name(record)returns true forNetworkMode::NoNetas well asNetworkMode::HostNetwhenrecord.box_addressesisNone, the same modes ascreate.rsholds_name_with_vm_host. Then the dashboard's destroy (dash/rpc.rssettle_destroyed_box, line 385) releases anonebox's hold, andmin session rename(cmd/session.rsline 736) moves it to the new name. Add a test for each path. Update the comment atcreate.rslines 2709-2713 to match. Without it, a destroyednonebox's name answers NODATA, not NXDOMAIN, until the VM host daemon restarts, and a renamed box's audit records carry its old name. - C2:
crates/minimal/src/cmd/boxes/vm_host.rsrehold_held_name_before_attachre-holds the name of a namednonebox (NetworkMode::NoNet, nobox_addresses) on a VM host before an attach or exec, as it does for ahost_ipbox. Keep the egress re-admit (host_ip_box_with_vm_host) forHostNetonly. Without it, after a VM host daemon restart the hold of anonebox expires atHELD_NAME_RECONFIRM_BOUND,control.rsno_switch_box_namefinds no box, and the host refuses that box's expose decision report, so the decision is not audited.
Ruled at 15cf459 against gominimal/arch@7a86ec7bb3c0 by claude-opus-5-5; arch_rulings 893, job 51d6afa1-02dc-43b4-89ef-883b6cd4e6ef.