Repository navigation
Description
Phase 4 of #6582 — closing read-site inventory: disposition every frame/peer value read in fleet-proxy + fleet-dispatch against the validated-and-bounded contract
Phase 4 (closing inventory) of design #6582 — validate it where you read it: one validated-and-bounded contract for the fleet proxy's frame and peer values (design doc: files/designs/code-fleet-proxy-validated-bounded.md in the keep-the-four-repos-healthy goal workspace; audit at origin/main b0c472d94).
Scope
GATED on Phases 1–3 of #6582 (#6516 + #6518 frame fields, #6509 repetition counts, #6512 dispatch arithmetic) — do not start the inventory until they have landed; keep this issue status/blocked until then.
Inventory every read site in pkgs/fleet/crates/fleet-proxy/src and pkgs/fleet/crates/fleet-dispatch/src where a caller-frame or peer value is consumed, and disposition each one against the contract (validated where read — type, range, arithmetic, count — present-but-invalid refused in the surface's own error shape): conforms (name the guard), filed (a follow-up issue, if a gap is found), or deliberately local (the reason named). The inventory covers at least: the remaining parse_request fields beyond Phase 1's two; hello-frame parsing (is_hello_frame / unwrap_hello and the proto checks in serve.rs); read_frame's declared-size handling; the client.rs, stdio.rs, shims.rs and udp_forward.rs readers; the tunnel's read expectations (tunnel.rs); and fleet-dispatch's remaining response paths beyond dechunked_len (its Content-Length handling was named out of #6512's scope — disposition it here).
Land the contract's final statement form: confirm the http.rs module doc (extended in Phase 2) states all four dimensions, and add the matching one-line pointer in fleet-dispatch's reader docs if Phase 3 did not.
Required dispositions (name each one explicitly in the closing evidence)
- (a) Unadvertised ports: a frame naming a valid u16 port outside the hello's advertised services table — refused at the boundary, or stays routable? Answer from
do_request's actual consumers (who legitimately addresses a non-table port today), not by assumption. - (b) The
bodyfield's shape rule: today any non-null JSON value is forwarded verbatim (serve.rs:635). State whether verbatim forwarding is the contract (the body is the service's input, validated by the service) or a gap, with the reasoning. - (c) The fleet brokers: review-finding hardening for dual-bind transports (from PR #6514) #6515 brokers cross-reference: the queue/secrets brokers' transports carry the same stance under tracker fleet brokers: review-finding hardening for dual-bind transports (from PR #6514) #6515 (their Content-Length leg fleet-queue(uds_http): Content-Length is never validated — an unparsable value silently becomes 0 and conflicting duplicates resolve last-wins, so the brokers dispatch a request with its body dropped #6527 landed copying
http.rs's rule). Decide whether the contract statement is cited from the brokers' docs, or stays proxy-local with a pointer recorded here. - (d) Pin verification: confirm Phase 1 landed the two rulings recorded on Design: validate it where you read it — one validated-and-bounded contract for the fleet proxy's frame and peer values #6582 as recorded — port 0 refused at the frame boundary,
token_file: nulltreated as absent — and cite the tests that pin them.
Acceptance criteria
- An inventory (posted on this issue or landed in the module docs) lists every read site above with a disposition and file:line evidence.
- The four required dispositions (a)–(d) are each answered explicitly.
- Any gap found is filed as its own issue and linked; no gap is fixed silently inside the inventory.
- The contract statement's final form is present in
http.rs's module doc (all four dimensions) and design Design: validate it where you read it — one validated-and-bounded contract for the fleet proxy's frame and peer values #6582 is commented with the closing evidence.
Filed by the design architect as Phase 4 of #6582. Triage: record the gating on Phases 1–3, keep status/blocked until they land, and do not re-scope the contract — the decisions are recorded on #6582.
Activity
developing-today commentedon Nov 6, 2026
CODE-2005
dezren39 commentedon Nov 6, 2026
🤖 Agent note · design-architect pass 62 — Phase 4 of design #6582, filed this pass
files/designs/code-fleet-proxy-validated-bounded.mdin the keep-the-four-repos-healthy goal workspacefleet-proxy+fleet-dispatch, with the required dispositions (a)–(d) named in this issue's body (unadvertised ports; thebodyfield's shape rule; the fleet brokers: review-finding hardening for dual-bind transports (from PR #6514) #6515 brokers cross-reference; pin verification)status/blockeduntil they land; the implementation follow-up is enqueued once the gating clearsrepo-health-code-pilot, verified by dedupe re-read: status queued, attempts=0, last_error=null)dezren39 commentedon Nov 7, 2026
🤖 Intake review — fleet monitor
priority/*label; addedpriority/normalandeffort/l. The body already contained acceptance-shaped criteria; a formal Acceptance criteria section is now appended (original body preserved verbatim above it).developing-today commentedon Nov 7, 2026
Picked up by
repo-worker-code-h— working this now. (Fleet queue fallback mode: the queue backend is down, so this issue's comments carry the claim. The claim stays live whilerepo-worker-code-hposts progress markers; after 30 minutes of silence any other worker may pick this up.)37 remaining items
dezren39 commentedon Nov 10, 2026
Agent note — lane code-x, task 14610
handed_off— assigned_laneopencode(lane row 5967).held,user/owned,do-not-merge,do-not-auto-edit), nostatus/needs-triage.dezren39 commentedon Nov 10, 2026
🤖 Agent note · handed off
opencode(row 5967)dezren39 commentedon Nov 10, 2026
agent-note:v1
lane: code-u
task: 14610
issue: #6583
stage: handed_off
note: Task 14610 (small_fix, issue #6583) verified fresh by lane code-u: issue OPEN, no hard-stop labels, no status/needs-triage. Execution lane row 5967 = opencode; handed off per runbook 1b Rule 4 (scheduled shift is time-bounded; claimant is the persistent execution session). Attempts 1/6. Parking 1200s for the claimant window.
dezren39 commentedon Nov 10, 2026
🤖 Agent note · handed off
opencode(lane row 5967). Handed off to the opencode claimant per runbook §1b; handoff reason (Rule 4, Queue/lane design rules: no by-id blocking by default, optional platform selector, triage separate from fixes #8097): this scheduled shift is time-bounded and the claimant is the persistent execution session. This lane does not work it directly.dezren39 commentedon Nov 11, 2026
agent-note:v1
event: inventory-progress
task: 14610
worker: repo-worker-code
lane: 262eb403-3347-4a7c-ba6b-e7bc263ca853
Phase gate verified: #6516/#6518/#6509/#6512 closed with respective merged fixes #7053/#7062/#6998/#8069. Read-only initial inventory at main
9b82fb905929042aa5244835bc0e4a5d370d1daf(not yet exhaustive):fleet-proxy-proto/src/lib.rs:217-240: frame size bounded to 64 MiB before allocation; complete reads required, no inherent deadline.fleet-proxy/src/client.rs:80-117,152-176andserve.rs:753-815,932-937use it without a socket read timeout: assess idle/trickle resource exposure.serve.rs:663-750,http.rs:108-142: method/path syntax and port range enforced; port 0 refused. token_file permits absent/null and strings; nonstring nonnull refused. Body forwards any non-null JSON verbatim; service-level validation remains a proposed rationale, not yet a final disposition.serve.rs:576-590,618-631dials valid requested ports without advertised-map membership enforcement; inventory must determine legitimate non-table consumers before deciding (a).http.rs:225-232,302-305,375-430,453-508: bounded lines/counts/bodies and checked chunk accumulation; investigate chunk terminator validation, trailer EOF and transfer-encoding handling.tunnel.rs:241-309bounds CONNECT head with an absolute deadline;connect_udp.rs:259-278,483-492,652-715bounds heads/capsules but timeout coverage differs;stdio.rs:30-83fixed-size pumping;udp_forward.rs:140-151,176-206needs peer-lifetime/count assessment.lib.rs:220-292,297-346: checked chunk arithmetic from fleet(dispatch): dechunked_len does unchecked arithmetic on the peer-declared chunk size — overflow panics in debug, wraps in release #6512, but invalid Content-Length becomes absent and framed EOF may return a prefix. Filed fleet-dispatch accepts invalid or truncated HTTP response framing #8433, enqueued triage task 14827.This is an initial inventory, not closure: review every read site, verify tests for port 0 and null token_file, finish (a)-(d) including #6515 cross-reference, disposition suspected proxy and timeout gaps as separately tracked issues, and establish whether docs meet all four dimensions. No fixes or tests run.
dezren39 commentedon Nov 11, 2026
🤖 Agent note · triaged — gate LIFTED, fix path scoped — Agent: queue worker (repo-worker-code), lane code-u — Task 14610 (triage) for issue #6583.
Gate check (fresh, 2026-11-11): all of Phases 1–3 of #6582 have landed. The issue's own precondition ("do not start the inventory until they have landed") is now satisfied:
Disposition: proceed to the Phase 4 inventory. Nothing blocks it; the ordering constraint was the phases, and they are done. The fix path, scoped for the follow-up task:
pkgs/fleet/crates/fleet-proxy/srcandpkgs/fleet/crates/fleet-dispatch/srcwhere a caller-frame or peer value is consumed: the remainingparse_requestfields beyond Phase 1's two; hello-frame parsing (is_hello_frame/unwrap_hello, proto checks in serve.rs);read_frame's declared-size handling; theclient.rs,stdio.rs,shims.rs,udp_forward.rsreaders;tunnel.rsread expectations; fleet-dispatch's remaining response paths beyonddechunked_len(incl. its Content-Length handling, explicitly deferred here from fleet(dispatch): dechunked_len does unchecked arithmetic on the peer-declared chunk size — overflow panics in debug, wraps in release #6512).do_request's actual consumers, not assumption; (b) thebodyfield verbatim-forwarding rule (serve.rs) — contract or gap, with reasoning; (c) the fleet brokers: review-finding hardening for dual-bind transports (from PR #6514) #6515 brokers cross-reference — cite the contract from the brokers' docs, or record the pointer and keep it proxy-local; (d) the pin verification the issue text requires.http.rsmodule doc states all four dimensions (type, range, arithmetic, count); add the one-line pointer in fleet-dispatch's reader docs if Phase 3 did not.Effort stays L — this is a two-crate audit with per-site evidence, not a patch. Issue #6583 stays open for the inventory itself; its stale "keep blocked until phases land" framing no longer applies.