route-record: version 3 states what a hop delivered by its count and root, so a hop may deliver any number of objects #563
Loading…
Reference in a new issue
No description provided.
Delete branch "wai/route-outputs"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The bound. Route record version 2 lists the served attempt's outputs, at most 1024 (route-record §5.2), and the list grows with them. A package's run delivers its receipt, its indexes and one object per piece and rung, so a long title's package has thousands of objects. Such a record cannot be stated.
seal_delivereddoes not bound the list, so a router sealed a record that WAI's own verifier then refuses.Route record version 3 (
extensions/route-record.md§3.4, §5.2, §6, §6.1), on a price book of version 2:delivered: the count of the objects it delivered, and their commitment, which is the root its hop's receipt already names (oer-receipts §3 Output). A failed attempt states 0 and zeros.receipt_output_mismatch). A record of version 1 rests on a price book of version 1, and one of version 2 or 3 on a price book of version 2 (pricebook_mismatch).An output's inclusion proof (§6.1):
indexandsiblings, from the leaf up. It is held as jwp-receipts §3 step 5 holds an object:So the last node of an odd level is proved at its own index only.
The receipt ledger (
extensions/receipt-ledger.md§5.1, §4.8). Under a route record of version 3, each output of a job source givesproof:output_not_delivered.malformed.Reason. The hop's receipt names only the root, so the count is the router's statement, which only the objects check. A count stated larger than the objects lets one object be proved at a second place, but no source bills one object twice, and a decode is held to its places and its count. Every tariff version that reads job sources reads these.
Reference:
route_record::seal_committed,output_proof,verify_output_proof,book_version.Corpora.
Routes: 109 → 126 vectors. Six are accepted:
Eleven are controls:
deliveredin a record of version 2;Ledger: 108 → 120 vectors. One is accepted: an encode whose clip is the second of two objects, a decode of version 5, and a package's run whose receipt is the first of 1,501 objects, each output proved. Eleven are controls:
Unchanged. Every other vector and source of both corpora is unchanged byte for byte, except one acknowledged break: the unknown-version control is now
record_version_4.Checked.
wai-rs on Linux, with CI's features:
--lib route_record::9 passed, including an inclusion-proof test over every output of every count to 37;--lib receipt_ledger::13 passed,--lib png_still::6 passed;--test route_record7,--test receipt_ledger7 (both corpora regenerate byte for byte),--test revenue_share7,--test opportunity_report6,--test corpus_provenance2, all passed.wai-ledger: release tests 5 passed, and clippy
-D warningsis clean.route_record_verify.py, sharing no code with wai-rs:delivered-formandreceipt-rootamong them.receipt_ledger_verify.py:output-proofamong them;inclusion_proof.Dependent verifiers: those of the corpora that read the ledger's (revenue share, opportunity report) pass.
Rust falsification: each rule mutated alone in the reference (16 mutations, scratchpad
falsify_rr3.py), each run against a passing baseline and checked by both corpora'sverifybinaries.deliveredrequired; a served count of at least 1; a failed root of zeros; version 3 resting on a version-2 price book; the receipt naming the root; version 3's candidates being version 2's; and the proof's index below the count, its sibling count, its walk from the leaf, and its bit's side.15 of 16 are caught, and the restored tree passes. The one that survives is the exact sibling count. The leaf and node domains already keep a walk of another length from reaching the root (a different length would need a hash collision), so no vector can isolate it. It stays as jwp-receipts §3 step 5 states it, refusing such a proof before anything is hashed, and §6.1 now says so.
Also: a flaky test on main
joule-contrib'sa_wrapped_key_unwraps_under_the_passphrase_onlychecked that encryption under a random key changed the payload's first byte, which stays the same one time in 256. It failed that way on linux-arm64 at this PR's first head. Its own commit (5c4759516) makes it compare the whole payload.joule-moq-ingest'scontribution_at_twenty_megabits_passes_the_doorlost two of 120 access units mid-stream on linux-arm64, on a heavily loaded host. Its link ran at a 300 ms window, so a longer stall has the gateway drop a packet as too late. Its own commit (189b9a92f) gives the link 2 s, closes once every packet is acknowledged, and checks the link record for too-late drops before comparing frames.🤖 Generated with Claude Code