Repository navigation
T67 — Move the reserved local range to the design's 127.0.64.0/24 - #1761
norrietaylor merged 2 commits into
Conversation
The design (18-spec-box-networking §7.1) puts the reserved local range published addresses come from at 127.0.64.0/24; the constant carried 127.64.0.0/24, a different block of the same loopback /8. Move the definition and the default plan's slice tests to the design's block, and with them the bind-probe tests' literals, which name the range the same constant feeds.
Every reader of the moved range followed it to 127.0.64.0/24: the zone's and the slice-octet docs restated the block they re-export from the switch constant, the host-answerable tests and their outside cases now pin the /24's new boundary, the slice-log and session-start probe tests carry the new literals, the min CLI's naming-surface record and bundle probe record do too, and the session e2e's accepted-resolution pattern accepts the new block's addresses. No behavior changes here: the code already reads the one definition, which commit 1 moved.
|
Important Review skippedBot user detected. To trigger a single review, invoke the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
|
Approved: no findings at Nothing to do. Verdict APPROVE, posted as a comment: the App cannot review its own pull request; the check and the label carry it. Clobber: none: |
There was a problem hiding this comment.
Reviewed against the T67 plan block: pure move of the reserved local range to the design's 127.0.64.0/24, every carrier reads the switch constant, no old-range literal remains at the head. The out-of-layer files are literals forced by the moved constant. The third test line's exit 4 is the plan block naming NET-010's verify test, which no layer of this task adds; that test belongs to T14.
T67 — Move the reserved local range to the design's 127.0.64.0/24
slice: S3
kind: task
covers: NET-010, NET-127
size: S
est: 40 code, 120 tests
executor: agent
difficulty: routine
model: standard
diagnostics: the daemon log's slice line names the new range
observability: unchanged; the range shows in the existing slice and answerer log lines
layers:
- switch:
- crates/switch/src/lib.rs:
RESERVED_LOCAL_RANGEand the default address plan carry127.0.64.0/24; the slice tests followtest: cargo nextest run -p switch loopback_slices_disjoint_per_switch
- daemon:
- crates/minimald/src/net/dns.rs: reads the range from the switch crate and drops its own copy
- crates/minimald/src/net/answerer.rs: the host-answerable tests use addresses in the new range
- crates/minimald/src/server.rs: the slice-log tests and their literals follow
- crates/minimald/src/sessions.rs: the doc comment names the new range
test: cargo nextest run -p minimald host_zone_a_answers_confined_to_local_addresses
test: cargo nextest run -p minimald each_box_gets_own_loopback_address
produces: none
consumes:
- crates/switch/src/lib.rs
proof: The reserved local range every published loopback address is allocated from is the design's 127.0.64.0/24, in the switch crate's address plan and everywhere the daemon reads it, with the answerer, the loopback slices and the resolver advisory all naming that range.
depends on:
- blocked by #1633
Proof
The reserved local range every published loopback address is allocated from is the design's 127.0.64.0/24: the switch crate's RESERVED_LOCAL_RANGE and default address plan now carry it (slices tile 127.0.64.0-127.0.64.255 eight /27s at a time), the daemon's zone re-exports and doc comments name it, the host-answerable guard and its tests accept exactly that block, the slice-log and session-start probe lines print it, the resolver advisory's naming surface reports it, and the session e2e accepts answers from it. Previously every one of those named 127.64.0.0/24, a different block of the loopback /8.
Notes from the agent: Out-of-layer files I had to touch, all forced by the constant's move — literals and an acceptance pattern of the old block, not new behavior: crates/switch/src/loopback.rs (bind-probe tests' first-refusal literals), crates/minimald/src/rpc.rs (the probe stand-in and the session-start probe line's summary literal), crates/minimal/src/resolver.rs (the naming-surface and bundle-probe record literals), scripts/session-e2e.sh (the case that accepts a native resolution; the old pattern would have failed every e2e run against the new range). The third test line cannot pass on this tree: no test named each_box_gets_own_loopback_address exists anywhere in the workspace, and no layer line of this task adds one. NET-010's verify test belongs to the task that lands its publish path — LoopbackAllocator::allocate has no caller by design ('#[allow(dead_code)] // The publish path (NET-129/NET-010) is another task's', crates/minimald/src/sessions.rs) and its harness requires host-global allocation separate from any daemon's own state, which the current per-daemon allocator is not. I did not write a placeholder under that name: it would pin the per-daemon allocator design the spec's harness explicitly rules out, and would falsely mark NET-010 green. The address half this tree does support is covered by loopback_slices_disjoint_per_switch (switch) and loop…[truncated]
Tests
cargo nextest run -p switch loopback_slices_disjoint_per_switchcargo nextest run -p minimald host_zone_a_answers_confined_to_local_addressescargo nextest run -p minimald each_box_gets_own_loopback_addressVerify
min task run agent-verifypassed ([tasks.verify]).Out of scope
These files are outside the task's
layers:, so this PR is a draft:crates/minimal/src/resolver.rscrates/minimald/src/rpc.rscrates/switch/src/loopback.rsscripts/session-e2e.shCloses #1726