P2: later
An appendix to the milestone.
-
The one piece of logic beyond the grants has no proof. DONE:
Ports::nextreturnsOption<u16>and the socket table answersREP_ERRwhen every port is held. Three Kani harnesses with falsification patches: the position and clock, the loop (an_allocation_never_moves_the_cursor_back_or_returns_a_held_port) and the no-reuse arithmetic (a_stack_started_four_milliseconds_later_starts_past_every_port_used). The loop proof bounds the loop at four candidates throughnext_within. A proof over the whole range of 16384 did not finish in over an hour at 6 GiB. That the full-range loop behaves like the bounded one is an argument, not a proof. Finding: the three harnesses prove the grant packing and checks, which is the authority. The frame layout, the badge predicate and the lease round trip are tests of fixed values, which is enough for constants.ephemeral::Ports::next(lines 331 to 341) is a loop with a clock, a modulus and a fallback, proven by nothing. Its central claim is that a stack started a clock tick after another hands out none of its ports. A sampled test covers that claim over five start times and 1,997 gaps (lines 388 to 401). The fallback at line 340 returns a port theheldpredicate refused when every port is in use, silently. Evidence: the lines above;README.md"What is proven". Change: two bounded harnesses. One: for any cursor position, anymillisecondsand anyheldanswer, the port returned lies inLO..=HIand the cursor never moves backwards. Two: for anylastand anygapof at least1000 / PER_SECONDrounded up,clock(last + gap)exceeds the position a cursor reaches afternopensgapart wheng * PER_SECOND >= 1000, which is the no-reuse claim as arithmetic rather than samples. Each with a falsification patch (the existing ephemeral patch falsifies the test and can falsify the harness too). Document the fallback, or makenextreturnOption<u16>and let the stack answerREP_ERR; the second is the honest shape and costs onematchinsocket_table.rs. Door: two-way (an unreleased signature). Effort: M. -
Offsets, lengths and byte orders mix types and go unstated. WILL NOT FIX in part (provisional, ruled 2026-11-22 UTC):
FRAME_BYTESnames the frame size and the byte order is stated once. The offsets stayu64, the typeuser_mode_runtime's window API takes, andMAXIMUM_PAYLOAD_BYTESstaysusize, the type arrays and slices take, so neither consumer casts its own constant. Finding:OFF_*areu64andDATA_MAXIMUMisusize, so every caller casts (DATA_MAXIMUM as u64at five sites incomponents/,PAYLOAD_OFFSET_BYTES as usizein the crate's own line 471).DATA_MAXIMUM = 4096 - PAYLOAD_OFFSET_BYTEShardcodes the page size with no constant for it;user_mode_runtimebrings its ownPAGE. The text gives the byte order fordst_portalone ("little-endian", line 456). It gives none forlen. The std layer comments that it matches (nife.rsline 219). The lease word is big-endian in the low 32 bits, so one contract carries two byte orders without saying it has two. Evidence:lib.rslines 454 to 471 and 534 to 537;socket_frame.rsline 35. Change: one type for offsets and lengths (usize, ascore::ptr::addand slices take). Add aFRAME_BYTESconstant (name provisional) of 4096 thatDATA_MAXIMUMderives from and the client runtime can import. Add one sentence to the layout note: every multi-byte frame field is little-endian, and aleaseword carries the address big-endian in its low 32 bits because that is the way an address reads. Door: two-way before the release; the types become one-way after. Effort: S. -
Names where this review reads a later rule differently from the package. DONE: the architect ratified the names as built (2026-11-20 UTC);
tcp,udpandipv4stay abbreviated (ruled 2026-11-16 UTC). Finding: the package proposes keepingPorts::nextandpolled_wait::next. The rule that a method takes std's spelling asks for std's meaning too;Iterator::nexttakes no argument and returnsOption, whilePorts::next(milliseconds, held)takes two and returns au16, andpolled_wait::next(now, last_frame, tick, ...)is a pure decision.fixture::IN_MSGandOUT_MSGabbreviatemessage; the package proposes nothing forfixturebecause its decision 2 moves the module.udp,tcpandipappear in public names and are in neither the template's[spelled_out]nor its[accepted]list, so the gate neither refuses nor records them. Evidence:lib.rslines 239, 331, 488, 490;vendor/crate-workflows/helpers/naming_words.toml[accepted]; the package's names table. Change: proposals for the architect's naming pass, all provisional. Rename toPorts::allocate(it acts and reports, likeclaim), andpolled_wait::decideorwait_decision. UseIN_MESSAGEandOUT_MESSAGEiffixturestays long enough to matter. Addudp,tcpandipto the template's[accepted]with their reasons ("nobody says User Datagram Protocol in a name"), so the rule has a record rather than passing by silence. Door: two-way. Effort: S, in the package's rename lane. -
Inline "name provisional" prose survives the move. DONE: the crate's doc comments no longer say "provisional" in a sentence, and every
Name:block reads ratified; the move strips the blocks. Finding: the move stripsName:blocks. The crate also carries the words inside ordinary sentences: "Names provisional." (line 65), "Name provisional." (lines 74, 84), "Names provisional." (line 440), "The module's name is provisional." (lines 213, 292), and "provisional, as is the name" (line 516). A stranger reads them in rustdoc with no idea whose ruling is pending. Line 22 names the decider inside the crate docs. Evidence: the lines above. Change: move each into the item'sName:block, which the move strips, or delete it at the move. Line 22 becomes aName:block in the recorded form. Door: two-way. Effort: S. -
The documentation refers to things the crate does not define. DONE (a Vocabulary section in the crate documentation). Finding:
PageFrame(line 451) is a kernel type;SEND_CAPABILITY,CALL,WRITE | GRANT,BADGE,UNMAP(lines 46, 442 to 448) are kernel operations and rights; "the kernel-stamped" badge assumes the reader knows the kernel stamps badges. The package listsPageFrame. A reader of the crate alone has no link to follow. Evidence: the lines above. Change: one "Vocabulary" paragraph in the crate documentation. It says, in a sentence each, what a capability, a badge, aCALLand the shared frame are in the system this contract assumes. It also says which crate (abi) names the operations, without a path into nife. Door: two-way. Effort: S.