carlos / platform Public

design-roster-revision-holds rev 2: Astra round 1 (compatibility contract, fresh authority vs cleanup identity, recovery binding checks, production tests, survey additions)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
claude agent, operated by paul@keymail.dev 0a0b4b2c7404b970e0a7518dc707a3309aedef11 parent 212022a
1 file changed, +168 −89
  • docs/superpowers/notes/design-roster-revision-holds.md +168 −89

CI passed — run details

diff --git a/docs/superpowers/notes/design-roster-revision-holds.md b/docs/superpowers/notes/design-roster-revision-holds.md
index cc117ca94..9fc072e34 100644
--- a/docs/superpowers/notes/design-roster-revision-holds.md
+++ b/docs/superpowers/notes/design-roster-revision-holds.md
@@ -1,6 +1,20 @@
# Design: roster revision vs hold churn (host claims, G10)
-Status: PROPOSED (2026-10-20). Branch `claim-empty-cohort-done` at 500741f4. Static reading only; nothing built or run.
+Status: PROPOSED, rev 2 (2026-10-20). Branch `claim-empty-cohort-done` at 500741f4. Static reading only; nothing built or run.
+
+## Rev 2
+
+Astra's review of rev 1 (212022a8) returned DESIGN: revise. Each finding, its ruling and where rev 2 resolves it:
+
+| Astra | Ruling | Resolution |
+|---|---|---|
+| 1 HIGH: digest receipts break the v0.28.4 console (purge's `StopBeforeTeardown`, wake-reset verification) | R1: the dev console stays on v0.28.4; internal comparisons bind on `Binding`; every console-verified artifact keeps `DirectoryRevision` as the numeral and carries the binding in a new additive field only where the console decoder tolerates unknown fields; no console or hostops verifier changes | section 2 C1 "Compatibility contract", section 1.4 (artifact and decoder survey), plan tasks 4 and 8 |
+| 2 MEDIUM: root's inventory comparison uses the startup-pinned cleanup actor in instance-control mode | R2: separate the historical cleanup identity from the fresh authority | section 3.2, plan task 5, test L4 |
+| 3 MEDIUM: recovery rebind and handover recovery re-stamp a predecessor without checking its stamp | R3: not an exception; predecessor-binding checks before reuse; cold handover named as the one path across a binding change, with its authority | section 3.3, plan task 6, test L6 |
+| 4 MEDIUM: the witness did not establish the invariant (no `ReconcileAdapter.CheckLocal`; floor change tripped the floor check, not the binding; local path only; no restart cases) | R4: adopt the corrections | section 4 tests L0 to L7 |
+| 5 LOW: missing readers and two misclassified producers; numeric `Revision` must stay in several places | R5 | section 1.2 rows marked "rev 2", section 1.3 "Numeric Revision stays" |
+| Role excluded; historical stop evidence format-only; wake-reset keeps its actor checks | R6 | section 2 tuple, section 1.4 |
+| Pre-roll check for leo beyond "no running instances" | R7 | plan task 9 |
## The gap
@@ -23,13 +37,13 @@ Every roster write goes through `Directory.Replace` (`internal/hostactors/roster
| Readmission | hostresolve/readmit.go:131-136 | row `State: active` | yes | yes |
| Retire | no writer in the tree; `Validate` accepts the state (roster.go:122), `Replace` refuses un-retiring (roster.go:270) | row `State: retired` | yes, when one lands | yes |
| `SetBoxRole`, `SetGroupRole` | hostactors/roles.go:76-91, 114-138; console/apiboxroles.go:147,187 | row `Role`, `Regions[r].Role` | yes | placement only |
-| `PublishFloor` | hostactors/publication.go:14-78 | `Publication`, `FloorSHA256` (two writes: :31, :77) | yes, twice | yes |
+| `PublishFloor` | hostactors/publication.go:14-78 | `Publication`, `FloorSHA256` (two writes: :31, :77); after publication `checkMembership` refuses any floor change (membership.go:241) | yes, twice | yes |
| `BindCensusKey` | hostactors/censuskey.go:25-95 (`next.Revision++` at :78) | row `CensusPublicKey` (write-once) | yes | yes |
| Hold reserve (`ReserveLifecycle` -> `Reserve`) | hostactors/lifecycle.go:135-155, census.go:246-294 (:293); caller hostops/production_held_start.go:32 | `Holds[+id]` | yes | no |
| Hold release (`ReleaseFinishedHold`, `CancelHold`) | hostactors/lifecycle.go:157-180, reservations.go:69-110; callers console/claim_hold_recovery.go:40,46, production_held_start.go:35,51 | `Holds[-id]` | yes | no |
| Activation reserve (`Reserve(activation=true)`) | census.go:246-294 (:281); console/hostactivation.go:193 | `Activations[+id]` | yes | no |
| Activation release, cancel | hostactors/activation_complete.go:13-57, activation_publication.go:22-50; console/hostreports.go:91, hostactivation.go:330 | `Activations[-id]` | yes | no |
-| Activation runner phases configure, home, enroll-console | claimactivation/runner.go:194, 203, 268 | `Regions`+`RequestLimitNS`; `HomeRegion`; `Consoles[id]` | yes | yes |
+| Activation runner phases configure, home, enroll-console | claimactivation/runner.go:194, 203, 268 | `Regions`+`RequestLimitNS`; `HomeRegion` (write-once with claims on, roster.go:216-217); `Consoles[id]` | yes | yes |
Not roster writes: `Invite` (invitation.go:30) and `InviteConsole` (console_invitation.go:15) write their own objects.
@@ -37,148 +51,213 @@ So it is not only holds. Activations are written on every platform promote (`res
### 1.2 Readers of `Revision` and `DirectoryRevision`
-"Hold churn should invalidate" is the design answer, not the current behaviour.
+"Treatment" is rev 2's answer. `Binding` is the per-box digest of section 2; "numeral" is `strconv.FormatUint(actor.Revision, 10)` as today.
Box agent (pinned once at assembly):
-| Reader | file:line | Compares | Protects | Hold churn should invalidate |
+| Reader | file:line | Compares | Protects | Treatment |
|---|---|---|---|---|
-| assembly pin | host/claimassembly.go:179-180 (`Reconcile.DirectoryRevision`, census), :381 (root's reconcile census from `actorForRoot`) | stamp source for every inventory this process writes | the installation is made by this enrollment under this roster | no |
-| `claimBoundIdentity` | host/claimmoveparks.go:97-110; wired at claimassembly.go:186-188 (data store), :243 (leases), :273 (move fence, move parks) | fresh actor == pinned actor, whole struct | the regional engine, moves and leases act only as the verified enrollment | no (still pinned; the regional worker dies on the first create, fix report concern 1) |
-| `VerifyRegional` | host/claimassembly.go:281-301 | `sameVerifiedActor` (all fields except `Revision`) since 7b805720 | same | no (done) |
-| install, route register | hostbox/reconcile_adapter.go:139; inventory_registration.go:80, 140, 249 | stored inventory == pinned stamp | an inventory this process did not write is refused | no |
-| local census | hostbox/empty_census.go:109, 135, 370 | same | same | no |
-| retirement | hostbox/reconcile_adapter.go:301 | inventory == fence target | the retirement parks only what root's inventory names | no (record to record) |
-| sanity | hostbox/identity.go:86 (`Revision > 0`), host/claimfilesseed_select.go:38, claimservingpark_transport.go:158, claimservingparkroot_linux.go:75 | non-zero | a roster row was read | no |
-| launch owner | host/claimconstruction.go:327 (`FenceTarget.DirectoryRevision` from the construction actor), claimroleassembly.go:58 | stamp into launch and fence records | a launch is tied to the enrollment that made it | no |
-| stop, retire, receipts | host/claimwakestop.go:34,49,308-313; claimstop.go:223,256,269,335,399,412,433; claimstop_writers.go:39,86,109,119,239-247; claimstop_recovery.go:64,82; claimstop_transport.go:207-211; claimretire_transport.go:145,180; claimjournal_proof.go:106,114; rootmigration_evidence.go:40; claimservinglegacy.go:48-49 | request == inventory == receipt (record to record) | a stop receipt proves the stop of exactly the installation it names | no, and these never read the live roster |
-| relocation effects | host/relocationeffects.go:38, 168, 275 | expected = fresh actor | a relocation stop runs under the current enrollment | no |
-| execution authority | host/rootexecution_authority.go:79; hostexec/rootbroker.go:254 (non-empty) | stamp into the lease authority | forensic | no |
-| journal digests | hostbox/journalservice.go:184, 208 (v1 tuple, frozen); journalmigration_linux.go:606, 680 (`legacyToken`: any printable ASCII up to 256) | hashed as a string | the journal request is bound to its target | n/a |
+| assembly pin | host/claimassembly.go:179-180 (`Reconcile.DirectoryRevision`, census), :381 (root's reconcile census) | stamp source for every inventory this process writes | the installation is made by this enrollment under this roster | stamp `actor.Binding`; stays pinned (fail closed after a binding change until restart, section 3.2) |
+| `claimBoundIdentity` | host/claimmoveparks.go:97-110; wired at claimassembly.go:186-188 (data store), :243 (leases), :273 (move fence, move parks) | fresh actor == pinned actor, whole struct | the regional engine, moves and leases act only as the verified enrollment | `sameVerifiedActor` (ignores `Revision`, compares `Binding` and every other field) |
+| `VerifyRegional` | host/claimassembly.go:281-301 | `sameVerifiedActor` since 7b805720 | same | unchanged; now also compares `Binding` |
+| install, route register | hostbox/reconcile_adapter.go:139; inventory_registration.go:80, 140, 249 | stored inventory == pinned stamp | an inventory this process did not write is refused | opaque string, unchanged code |
+| local census | hostbox/empty_census.go:99-135, 370 (`EmptyInstallationCensus.CheckLocal`, `Initialize`) | same, against the startup pin | same | unchanged code; the pin is a binding |
+| retirement | hostbox/reconcile_adapter.go:301 | inventory == fence target | the retirement parks only what root's inventory names | record to record, unchanged |
+| sanity (rev 2 rows added) | hostbox/identity.go:86 (`Revision > 0`); host/claimfilesseed_select.go:38; claimservingpark_transport.go:158; claimservingparkroot_linux.go:75; claimservingparksource_linux.go:33 (actor check, beside its inventory check at :41); claimservingreboot_prepare_linux.go:187 | non-zero | a roster row was read | `Binding != ""` (keep `Revision > 0` as well, it costs nothing) |
+| launch owner | host/claimconstruction.go:327 (`FenceTarget.DirectoryRevision` from the construction actor), claimroleassembly.go:58 | stamp into launch and fence records | a launch is tied to the enrollment that made it | stamp `actor.Binding` |
+| stop request fallbacks (rev 2: misclassified in rev 1) | host/claimwakestop.go:308-313 (`directoryRevision = fmt.Sprint(actor.Revision)` when no launch record), claimstop_writers.go:239-241 (`local.Actor.Revision`) | produce the expected stamp | the stop names the installation's binding | produce `actor.Binding`; the request also carries `RosterRevision` (section 1.4) |
+| stop, retire, receipts | host/claimstop.go:223, 256, 269, 335, 399, 412, 433; claimstop_writers.go:39, 86, 109, 119; claimstop_recovery.go:64, 82; claimstop_transport.go:207-211; claimretire_transport.go:145, 180; claimjournal_proof.go:106, 114; rootmigration_evidence.go:40; claimservinglegacy.go:48-49 | request == inventory == receipt (record to record) | a stop receipt proves the stop of exactly the installation it names | inventory, target and request slots carry the binding; receipt comparisons move to `receipt.Binding` (section 1.4) |
+| relocation effects | host/relocationeffects.go:38, 168, 275 | expected = fresh actor | a relocation stop runs under the current enrollment | `actor.Binding` |
+| execution authority | host/rootexecution_authority.go:79 -> rootparticipation/record.go:27 (`ExecutionAuthority.DirectoryRevision` string) -> hostexec/rootbroker.go:254 (non-empty) | stamp into the lease authority | forensic | carries `Binding` in the string field; the participation ledger's other revisions stay numeric |
+| evidence wiring (rev 2) | host/claim_evidence_wiring.go:61 (`cleanupEnrollment.actor != actor`, whole struct) | the stop coordinator's identity is the construction actor | same | unchanged; includes `Binding` after the change, both from one read |
+| journal digests and validation | hostbox/journalservice.go:184, 208 (v1 tuple, frozen); journalmigration_linux.go:606, 680 (`legacyToken`: printable ASCII up to 256); hostguard/fence.go:42; hostbox/stopinventory_db.go:42; generationpayload.go:56 (its `p.Revision` is the journal counter) | hashed or non-empty as a string | the journal request is bound to its target | opaque; no code change, no protocol version |
Root (fresh actor against the stored stamp):
-| Reader | file:line | Compares | Protects | Hold churn should invalidate |
+| Reader | file:line | Compares | Protects | Treatment |
|---|---|---|---|---|
-| inventory write | host/rootinventory.go:61-67; actor from `actorForRoot` (claimcleanup_identity.go:70-74: fresh, or the pinned cleanup actor in instance-control mode, :38) | `in.DirectoryRevision == fresh` | root records only inventories made under the roster it sees | no (this is G10's next stop) |
-| wake | host/rootinventory_state_linux.go:38 (remote), claimroleassembly_linux.go:373 (local), :47, :128 (target == inventory) | same | the instance wakes only under the roster it was installed under | no |
-| launch authorize | host/claimlaunch_authority.go:82, claimlaunch_root.go:180, 216 | fresh == `FenceTarget` (construction-time pin) | a launch runs only for the enrollment that reserved it | no |
-| serving handover | host/claimservinghandover.go:29-32; `servingPriorRevision` :136-139 (`prior <= fresh`, `next == fresh`); hostbox/servinghandover.go:50, 83, 140 | the prior may be older, the successor must be current, the inventory is re-stamped | a swap re-binds the installation to the current roster | no |
-| serving park, legacy | host/claimservingparkroot_linux.go:131, claimservingparksource_linux.go:41, claimservinglegacyroot_linux.go:44, 65, 102 | `prior <= fresh`, inventory == fresh | same | no |
-| cold handover, rebind | host/claimhandover_recovery.go:224, 243; claimhandover_transport.go:110; claimrecovery_remote.go:54; rootrecovery_rebind.go:35, 68; hostbox/coldhandover.go:122, 141, 336; generationhandover.go:19, 23 | successor stamp = fresh; re-stamps the inventory | same | no |
-| generations | host/rootgeneration_inventory.go:227 (non-empty), rootgeneration_parked.go:48, rootgeneration_handover.go:101, rootexecution_settle.go:96 | inventory == target | record to record | no |
-| startup census | host/rootinventory_startup.go:45 | pinned to the startup actor | same as the agent's census | no |
+| inventory write | host/rootinventory.go:61-67; actor from `InventoryActor` = `actorForRoot` (claimcleanup_identity.go:70-74: fresh, or the startup-pinned cleanup actor in instance-control mode) | `in.DirectoryRevision == actor` | root records only inventories made under the roster it sees | `== actor.Binding`, with `InventoryActor` always fresh (section 3.2) |
+| wake | host/rootinventory_state_linux.go:38 (remote), claimroleassembly_linux.go:373 (local), :47, :128 (target == inventory) | same | the instance wakes only under the roster it was installed under | `== actor.Binding` |
+| launch authorize | host/claimlaunch_authority.go:82 (actor is `a.Identity.Verify`, claimlaunch_production.go:70), claimlaunch_root.go:180, 216 | fresh == `FenceTarget` (construction-time stamp) | a launch runs only for the enrollment that reserved it | `== actor.Binding` |
+| serving handover | host/claimservinghandover.go:29-32; `servingPriorRevision` :136-139 (`prior <= fresh`, `next == fresh`); hostbox/servinghandover.go:50, 83, 140 | the prior may be older, the successor must be current, the inventory is re-stamped | a swap re-binds the installation to the current roster | prior and next both `== actor.Binding` (section 3.3) |
+| serving park, legacy | host/claimservingparkroot_linux.go:131, claimservingparksource_linux.go:41, claimservinglegacyroot_linux.go:44, 65, 102 | `prior <= fresh`, inventory == fresh | same | equality with `actor.Binding` |
+| recovery rebind, handover recovery | host/rootrecovery_rebind.go:68, 75, 136 (re-stamp at :35); claimhandover_recovery.go:217, 224, 243 | successor stamp = fresh; predecessor stamp never checked (:75, :217); re-stamped | an authorized recovery adopts the predecessor's artifacts | predecessor must equal `actor.Binding` before reuse (section 3.3) |
+| cold handover | hostbox/coldhandover.go:108-114 (prior's fence receipt verified), :122, :141 (inventory == prior target), :268 (prior parked), :336 (successor inventory: one route entry, fresh stamp); claimhandover_transport.go:110; claimretire_transport.go:56 | record to record for the prior; fresh for the successor | the prior is parked under its own stamp, nothing is adopted | unchanged: the one sanctioned path across a binding change (section 3.3) |
+| generations | host/rootgeneration_inventory.go:227 (non-empty), rootgeneration_parked.go:48, rootgeneration_handover.go:101, rootexecution_settle.go:96 | inventory == target | record to record | opaque, unchanged |
+| startup census | host/rootinventory_startup.go:45, :47 (`InventoryActor` = `actorForConstruction`) | pinned to the startup actor | same as the agent's census | stamp `actor.Binding`; `InventoryActor` fresh (section 3.2) |
+| migration preflight and fingerprint (rev 2) | host/rootmigration.go:59, 84-93; rootmigration_census.go:70-79 | plan and report pin `roster.Revision` (uint64) | the migration census is for one membership | numeric `Revision` stays |
Console and hostops:
-| Reader | file:line | Compares | Protects | Hold churn should invalidate |
+| Reader | file:line | Compares | Protects | Treatment |
|---|---|---|---|---|
-| backfill census `expectedRevision` | hostops/backfill.go:187-193; callers backfill_publish.go:32, 370, 437 and backfill.go:327 with `p.DirectoryRevision`; `Census()` for production create uses 0 (backfill.go:274-275, no pin) | `roster.Revision == plan.DirectoryRevision`, else `ErrPending` | the plan and every box report were taken against one membership | no. Today a hold in flight returns `ErrPending`, and once it releases the plan can never match again |
-| census reports | hostops/backfill.go:242, backfill_publish.go:169 (`Done`), 339, 395; claimactivation/backfill.go:159, 171, 203, 214, 246, 265; box side host/rootmigration_census.go:70-79 | `report.DirectoryRevision == roster.Revision` | a box-signed report is for this membership | no (same) |
-| stop evidence | hostops/evidence.go:123-124 (console), wake_reset_transport.go:318-319 (box) | `0 < recorded <= roster.Revision` | a receipt is not from the future | no (a sanity bound, never an authority) |
-| move loss grant | hostops/move_loss_grant.go:312-317 | the quarantine write is exactly `before.Revision+1` and changes one row | the loss grant's roster write is scoped | n/a (a write counter is right here) |
-| relocation start | hostactors/census.go:296-321 (`CheckBoxStart` returns `Revision`), :425-440 (`CensusBoxRelocation` re-reads and requires equality); hostrelocate/worker.go:341, 358; hostclaim/relocation.go:476, 511 (intent `directory_revision`, no reader) | change detection between two reads; forensic intent | nothing read it back | no (ETag would do) |
-| moves fence binding | hostfence/claim_fence.go:32 -> hostclaim/fence.go:75 (non-zero) -> relocating.go:136, 306 (journal `roster_revision`) | non-zero; journaled | forensic | no |
-| roles | console/apiboxroles.go:153, 193 | `next != o` means the write happened | logging | n/a |
-| activation CLI | claimactivation/runner.go:132, 143, 322; host/activation_command_linux.go:117, 237; activation_console_report_linux.go:240 | operator-supplied expected revision | offline CAS between phases; claims off, so no holds | n/a |
+| backfill census `expectedRevision` | hostops/backfill.go:187-193; callers backfill_publish.go:32, 370, 437 and backfill.go:327 with `p.DirectoryRevision`; `Census()` for production create uses 0 (backfill.go:274-275, no pin) | `roster.Revision == plan.DirectoryRevision`, else `ErrPending` | the plan and every box report were taken against one membership | numeric `Revision` stays; a hold in flight still returns `ErrPending` (deferred, section 3.4) |
+| census reports | hostops/backfill.go:242, backfill_publish.go:169 (`Done`), 339, 395; claimactivation/backfill.go:159, 171, 203, 214, 246, 265 | `report.DirectoryRevision == roster.Revision` (uint64) | a box-signed report is for this membership | numeric, unchanged |
+| stop evidence (purge, moves) | hostops/evidence.go:118 (`decode`, tolerant), :123-124 (`0 < recorded <= roster.Revision`); reached from `StopBeforeTeardown` (evidence.go:297, called by `FirstPhase` at production_create.go:351-353) and `verifyEvidence` | the receipt is not from the future, plus signature, enrollment, op, host, incarnation, fence | a sanity bound, never an authority | unchanged code; receipts keep a numeral there (section 1.4) |
+| wake-reset evidence | hostops/wake_reset_transport.go:280-300 (active, unfenced actor), :312 (`decode`, tolerant), :318-319 (same bound); wired by console/hostwakereset_production.go:16 | same, after the actor check | same | unchanged code; the actor check stays |
+| move loss grant | hostops/move_loss_grant.go:312-317 | the quarantine write is exactly `before.Revision+1` and changes one row | the loss grant's roster write is scoped | numeric, unchanged |
+| relocation start | hostactors/census.go:296-321 (`CheckBoxStart` returns `Revision`), :425-440 (`CensusBoxRelocation` re-reads and requires equality: activations are in scope, a per-box digest cannot replace it); hostrelocate/worker.go:341, 358; hostclaim/relocation.go:476, 511 (intent `directory_revision`, no reader) | two-read consistency; forensic intent | a relocation starts against one roster | numeric, unchanged |
+| moves fence binding | hostfence/claim_fence.go:32 -> hostclaim/fence.go:75 (non-zero) -> relocating.go:136, 306 (journal `roster_revision`, `roster_etag`) | audit metadata | forensic | numeric, unchanged |
+| roles | console/apiboxroles.go:153, 193 | `next != o` means the write happened | logging | unchanged |
+| activation CLI | claimactivation/runner.go:132, 143, 322; host/activation_command_linux.go:117, 237; activation_console_report_linux.go:240 | operator-supplied expected revision | offline CAS between phases; claims off, so no holds | numeric, unchanged |
| region HA | writers only (auto-enrol, roles); no reader | | | |
-| seeds | host/claimfilesseed_select.go:38 | non-zero | sanity | no |
-### 1.3 Findings
+### 1.3 Numeric `Revision` stays
-1. The roster is strict-decoded (`release.VerifyRootEnvelope` -> `strictCanonicalJSON`, release/rootenvelope.go:72-90: `DisallowUnknownFields` plus a canonical re-marshal). A new roster field, even `omitempty`, makes every older binary refuse `Directory.Read` once it is first written. The established pattern is I2 (censuskey.go:49-52): write the field only after a published floor excludes the older binaries. The `Roster` struct is byte-identical between v0.28.4 and this branch.
-2. `DirectoryRevision` is a string everywhere it is stored (inventory, fence target, launch record, stop request, receipt, execution authority) and is hashed as a string in the frozen journal v1 tuple. Only three readers parse it as a number for ordering: `servingPriorRevision` and the two stop-evidence sanity bounds.
-3. Handover and rebind already treat the stamp as re-bindable (they tolerate an older prior and write the fresh value). Wake and launch do not. That inconsistency is the defect's shape: a stamp that is a write counter can only ever be "current" by luck.
-4. The regional pin (`claimBoundIdentity`) and the install pin are the same pin: the `hostbox.Actor` struct carries `Revision`, so whole-actor equality carries the write counter.
-5. The cleanup (instance-control) actor is pinned at root construction (claimcleanup_identity.go:38), so root's inventory write compares a pin against a pin there and a pin against fresh elsewhere.
+Per R5, these keep the roster write counter and are not touched by this branch: relocation's two-read consistency check and start intent, the moves fence audit metadata, the activation CLI pins, the backfill and census pins, the migration preflight and snapshot fingerprint, the participation ledger's revisions, and the loss grant's `+1` scope. `Revision` keeps its one honest meaning, a signed write counter; `Binding` is a second value derived from the same signed read.
+
+### 1.4 Artifacts a console verifies, and their decoders (R1)
+
+The only box-produced artifact with a stamp that a console reads is the stop receipt (`host.StopReceipt`, claimstop.go:112; written at claimstop.go:335; bucket keys claimstop.go:505-507 `evidence/` and `serving-evidence/`, claimretire_transport.go:201 `-retirement.json`). Relocation's `Release` and `probe_stop` journals reference a receipt by key and sha256 (hostclaim/relocation.go:86-87, relocation_probestop.go:18-19); they never embed it. Census reports carry a uint64 numeral and are unchanged. Execution acks carry no stamp.
+
+| Decoder | file:line | Strict | Reads the receipt | Gets the `binding` field |
+|---|---|---|---|---|
+| `hostops.decode` | hostops/record.go:32-40 | no (trailing data only) | yes: evidence.go:118, wake_reset_transport.go:312 | yes: a v0.28.4 console ignores it |
+| `decodeClaim` | hostops/lifecycle_grant.go:115-120 | yes | no: it decodes the claim object, which references receipts by key | n/a |
+| `decodeMoveLossIntent` | hostops/move_loss_owner.go:115-117 | yes | no: the loss intent carries no receipt | n/a |
+| box-side receipt decoders | host/claimstop_transport.go:163, claimretire_transport.go:114, relocationreleases.go:42, verifyRetirementReceipt (claimretire_transport.go:174) | yes | yes | yes: agent and root are one binary on a box and update together |
+
+The contract:
+
+- `StopReceipt.DirectoryRevision` stays the numeral of the signed roster the stopping box read, carried in by a new `StopRequest.RosterRevision` (filled from `actor.Revision` at claimwakestop.go:313, relocationeffects.go:275, claimservinglegacy.go:48, claimstop_writers.go:247). Since `Revision` only grows, v0.28.4's `0 < recorded <= roster.Revision` holds for every later roster.
+- `StopReceipt.Binding string json:"binding,omitempty"` is new and carries the installation's binding (`req.ExpectedDirectoryRevision`). The box-internal receipt comparisons move to it: claimstop_transport.go:207, claimretire_transport.go:180, claimstop_recovery.go:82, rootmigration_evidence.go:40, and claimjournal_proof.go:106 (`wanted.Binding = inventory.DirectoryRevision`) with `legacyJournalProofMatch` (:114) digesting `Binding` in place of `DirectoryRevision`. The receipt's signature covers the raw bytes (`hostevidence.Verify` at evidence.go:115), so the added field is signed.
+- `StopRequest` and `WritersStoppedRequest` (box-internal, strict decoders at claimstop_transport.go:89 and claimstop_writers.go:143) gain `RosterRevision uint64`; `ExpectedDirectoryRevision` carries the binding.
+- `hostops.StopReceipt` (evidence.go:26-54), `evidence.go`, `wake_reset_transport.go` and `record.go` are not changed in this branch. The fix report records `git diff v0.28.4..HEAD --stat -- internal/hostops/evidence.go internal/hostops/wake_reset_transport.go internal/hostops/record.go` as empty.
+- Historical stop evidence is format-only on the stamp (R6), which is exactly what the unchanged v0.28.4 check is for a numeral. Wake-reset still requires an active, unfenced actor (wake_reset_transport.go:286-300).
+
+### 1.5 Findings
+
+1. The roster is strict-decoded (`release.VerifyRootEnvelope` -> `strictCanonicalJSON`, release/rootenvelope.go:72-90). A new roster field, even `omitempty`, makes every older binary refuse `Directory.Read` once first written; the I2 pattern (censuskey.go:49-52) gates such a write on a published floor. C1 adds no roster field. The `Roster` struct is byte-identical between v0.28.4 and this branch.
+2. `DirectoryRevision` is a string everywhere it is stored and is hashed as a string in the frozen journal v1 tuple. Inside the box only `servingPriorRevision` parses it as a number; outside the box only the two stop-evidence bounds do, and they keep receiving a numeral.
+3. Handover recovery and recovery rebind re-stamp a predecessor without checking its stamp (rootrecovery_rebind.go:75, :136; claimhandover_recovery.go:217, :243). Wake and launch require equality. Rev 2 makes recovery require equality too and names cold handover as the only path across a binding change.
+4. In instance-control mode root's `InventoryActor` is the startup-pinned cleanup actor (claimassembly.go:382 -> claimcleanup_identity.go:70-74; rootinventory_startup.go:47). Fresh verification (`RequireNewWork`) passes after readmission while the comparison still uses the startup value. Rev 2 splits the two.
+5. The cleanup actor is also the construction actor in that mode (claimproduction.go:139-141, claimconstruction.go:187, 229), so the producers' fence targets and the stop coordinator's identity come from the same startup read.
## 2. Options
-Common to all three: the roster stays root-signed; a hold write re-signs the whole object with the console's root key (console/claim_runtime.go:75 `Signer: release.RootSigner(s.cfg.Key)`), as today; boxes hold only the public key. Nothing new is signed by any option. Census reports stay box-signed and keep pinning `roster.Revision`.
+Common to all three: the roster stays root-signed; a hold write re-signs the whole object with the console's root key (console/claim_runtime.go:75 `Signer: release.RootSigner(s.cfg.Key)`), as today; boxes hold only the public key. Nothing new is signed by any option beyond the receipt field above, which rides under the receipt's existing box signature.
### A. Holds stop bumping `Revision`; the S3 ETag tracks hold changes
-`Replace` sets `next.Revision = before.Revision + 1` only when the roster minus `Holds` (and, to be useful, minus `Activations` and `EnrollmentAttempts`) differs; a reservation-only write keeps `Revision` and relies on the ETag CAS it already uses. `CensusBoxRelocation` compares ETags instead. Nothing reads `Revision` to detect a hold change (section 1.2), so no second counter is needed.
+`Replace` sets `next.Revision = before.Revision + 1` only when the roster minus `Holds` (and, to be useful, minus `Activations` and `EnrollmentAttempts`) differs; a reservation-only write keeps `Revision` and relies on the ETag CAS it already uses.
| Aspect | A |
|---|---|
| Code | console side only: `Replace`, `CensusBoxRelocation`, hostactors tests that assert `+1` (roles_test.go:147, 218; autoenroll_test.go:678; plan11_fix1_enrolled_test.go:29). Box, root, hostops untouched |
-| v0.28.4 console | its `Replace` keeps bumping on holds, so the defect persists until the console is updated. Order: console first; boxes need no release. Flagship is claims-off and writes no holds, so no exposure there |
+| v0.28.4 console | its `Replace` keeps bumping on holds, so the defect persists until the console is updated. The dev console stays on v0.28.4 (R1), so A does not fix the dev trial at all |
| Migration | none: stamps stay numerals and stay valid while membership is unchanged |
| Signing | unchanged |
-| Security | quarantine, readmission, retire, re-enrol, floor, home, census key: all still bump. But so does every other box's enrolment, every console enrolment, every role change. Region HA replacements would strand every installed instance in the deployment, and nothing re-stamps at wake |
+| Security | quarantine, readmission, retire, re-enrol, floor, home, census key still bump. So does every other box's enrolment, every console enrolment, every role change: region HA replacements would strand every installed instance, and nothing re-stamps at wake |
-A is cheap and compatible, and it fixes the G10 symptom, but it leaves `Revision` as a deployment-wide counter that still moves for reasons unrelated to the box.
+Rejected under R1.
### B. Holds move to their own object
-`control/host-holds.json` carries `Holds`; the roster keeps membership and activations.
-
| Aspect | B |
|---|---|
| Code | hostactors `Reserve`, `Start`, `CheckHold`, `CancelHold`, `ReleaseFinishedHold`, `Validate` (the hold/activation non-overlap rule at roster.go:173-179 and census.go:264-290 spans both objects), console hold recovery, `PublishFloor`'s "no holds" gate, every test that builds a roster with holds |
-| v0.28.4 console | writes holds into the roster. New code must read both places until it is gone; the overlap rule cannot be atomic across two objects while both exist |
-| Migration | existing holds (none at rest in a healthy deployment) copied or drained first |
-| Signing | a second root-signed object, re-signed on every hold write |
-| Security | the non-overlap of holds and activations loses its single CAS. Membership changes still bump `Revision`, so B fixes only holds, like A, at ten times the cost |
+| v0.28.4 console | writes holds into the roster for the whole dev trial; new code must read both places; the overlap rule cannot be atomic across two objects |
+| Migration | existing holds copied or drained first |
+| Signing | a second root-signed object |
+| Security | fixes only holds, like A, at ten times the cost |
Rejected.
### C. Boxes bind to a membership binding computed from the roster
-The box computes its binding from the signed roster it already reads, and that binding becomes the `DirectoryRevision` it stamps and compares. Two shapes:
-
-C1, a per-box digest, no roster change. `hostactors.BoxBinding(r Roster, ref string) string` is sha256 over a frozen v1 tuple: the deployment facts (`DeploymentBucket`, `HomeRegion`, `RequestLimitNS`, `Publication`, `FloorSHA256`) and the row's identity and state (`Enrollment`, `Namespace`, `BoxID`, `Region`, `Pool`, `Cloud`, `EvidenceSHA256`, `State`, `QuarantineRevision`, `CensusPublicKey`). Not in the tuple: `Revision`, `Holds`, `Activations`, `EnrollmentAttempts`, `Consoles`, `Regions`, other rows, `Role`, `Label`, `Group`, `LossIDs` (covered by `QuarantineRevision`), `EnrolledAt`.
+C1, a per-box digest, no roster change. `hostactors.BoxBinding(r Roster, ref string) (string, bool)` is sha256 over a frozen v1 tuple: the deployment facts (`DeploymentBucket`, `HomeRegion`, `RequestLimitNS`, `Publication`, `FloorSHA256`) and the row's identity and state (`Enrollment`, `Namespace`, `BoxID`, `Region`, `Pool`, `Cloud`, `EvidenceSHA256`, `State`, `QuarantineRevision`, `CensusPublicKey`). Not in the tuple: `Revision`, `Holds`, `Activations`, `EnrollmentAttempts`, `Consoles`, `Regions`, other rows, `Role` (R6; roles.go:12-15 keeps existing instances and `boxchoice.ExcludeRoles` enforces placement), `Label`, `Group`, `LossIDs` (covered by `QuarantineRevision`), `EnrolledAt`.
-C2, a stored counter. A new `membership_revision` (deployment-wide) or per-row `binding` field, bumped by `Replace` when the tuple above changes, read by boxes as today's `Revision`.
+C2, a stored counter (`membership_revision` or a per-row `binding`), bumped by `Replace` when the tuple changes. Rejected: a new roster field needs the I2 floor gate before its first write, which the v0.28.4 dev console cannot pass, so C2 is incompatible with R1 outright.
-| Aspect | C1 (digest) | C2 (stored counter) |
-|---|---|---|
-| Code, box and root | `hostbox.Actor.Revision` becomes `Binding string`; `productionClaimRoster.Actor` (claimproduction.go:396) and `verifyClaimCleanupEnrollment` (claimcleanup_identity.go:38) compute it; the 22 `fmt.Sprint(actor.Revision)` / `strconv.FormatUint(actor.Revision, 10)` stamp and compare sites use `actor.Binding`; `servingPriorRevision` becomes equality; `actorMatches` and the four `Revision == 0` sanity checks become `Binding != ""`; `sameVerifiedActor` is deleted (whole-actor equality no longer carries the counter) | same sites, but they keep numerals: `Actor.Revision` reads the new field, falling back to `Revision` while it is absent |
-| Code, console | hostops/evidence.go:123 and wake_reset_transport.go:318 accept a well-formed binding (64 hex) instead of parsing a bound. Nothing else | `Replace` and `BindCensusKey` maintain the field; a floor gate before the first write (I2 pattern) |
-| v0.28.4 console | fully compatible in any order: the old console's hold writes move `Revision`, which no box reads any more. The console must be on the new release before moves are switched on (its evidence check parses the stamp as a number). A v0.28.4 box stays broken by any console's holds until it is updated | the first write of the new field makes every v0.28.4 box and console refuse the roster. Order: every box and console updated, floor re-published with the new minimum, then the first write. Until then boxes behave as today |
-| Migration | an inventory, fence target or launch record stamped with a numeral never equals a digest: refused with `ErrTypedInventory` or `ErrChanged`, and the instance is reinstalled. Today there is nothing to migrate: leo is empty (trial Option B) and flagship is claims-off | the counter is seeded from `Revision` at the first write, so a stamp equals the seed only if no write happened since the install. Same practical answer: nothing to migrate today |
-| Signing | unchanged; the binding is derived from the verified payload | unchanged; the field rides in the signed payload |
-| Security, must invalidate | retire (`State`), re-enrol (`Enrollment`), quarantine (`State`, `QuarantineRevision`), readmission (`QuarantineRevision` only grows, so the post-readmit binding never equals the pre-quarantine one), floor publish (`FloorSHA256`, `Publication`), home region (`HomeRegion`), census key bind: all change the digest | same, by the bump rule |
-| Security, must not invalidate | holds, activations, enrollment attempts, console rows, region roles, other boxes, this box's role or label: not in the tuple | same, by the bump rule; a deployment-wide counter still moves for other boxes' rows unless it is per-row |
-| Ordering checks | the two stop-evidence bounds (`recorded <= Revision`) become format checks. They were never an authority: the receipt's signature, enrollment, op, host, incarnation and fence bind it, and any numeral at or below the current counter passed. `servingPriorRevision` becomes equality, which is what wake already requires | unchanged |
-| Cross-version mixing | the binding is computed and compared on one box by one binary. The only cross-party comparison is the console's evidence format check | same |
+| Aspect | C1 |
+|---|---|
+| Code, box and root | `hostbox.Actor` keeps `Revision` (numeral) and gains `Binding`; `productionClaimRoster.Actor` (claimproduction.go:396) and `verifyClaimCleanupEnrollment` (claimcleanup_identity.go:38) compute it from the roster they read; the 22 `fmt.Sprint(actor.Revision)` / `strconv.FormatUint(actor.Revision, 10)` stamp and compare sites use `actor.Binding`; `servingPriorRevision` becomes equality; the sanity checks add `Binding != ""`; `claimBoundIdentity` uses `sameVerifiedActor`; `InventoryActor` is always fresh; recovery checks the predecessor; the receipt carries numeral plus `binding` |
+| Code, console and hostops | none (R1) |
+| v0.28.4 console, dev | compatible in any order: the console's hold writes move `Revision`, which no internal comparison reads; the receipts it verifies keep a numeral. Order for dev: leo only. Flagship is claims-off |
+| v0.28.4 box | stays broken by any console's holds until it takes the release |
+| Migration | an inventory, fence target, launch record or receipt stamped under the old scheme never equals a binding: refused and the instance reinstalled. Task 9 proves there is nothing to migrate before the roll |
+| Signing | unchanged |
+| Security, must invalidate | retire (`State`), re-enrol (`Enrollment`), quarantine (`State`, `QuarantineRevision`), readmission (`QuarantineRevision` only grows), floor publish (`FloorSHA256`, `Publication`), home region (`HomeRegion`), census key bind: all change the digest. Same-reference re-enrolment and census-key rotation are refused by the normal writers (enroll.go:51-56, censuskey.go:66-71); tests simulate them by direct signed writes and say so |
+| Security, must not invalidate | holds, activations, enrollment attempts, console rows, regions, other boxes, this box's role or label |
+| Ordering checks | inside the box, `servingPriorRevision` becomes equality (what wake already requires). Outside the box the two bounds are untouched and keep seeing numerals |
## 3. Recommendation
-C1: the per-box binding digest, no roster change.
+C1, the per-box binding digest, no roster change, with the R1 compatibility contract.
**Invariant.** Installed state binds to `BoxBinding(roster, box)`, the digest of the deployment's binding facts (bucket, home region, request limit, publication, floor) and this box's row identity and state (enrollment, namespace, box id, region, pool, cloud identity, evidence digest, state, quarantine revision, census key). `BoxBinding` changes only when one of those facts changes. Holds, activations, enrollment attempts, consoles, regions, other boxes' rows, this box's role and label, and the roster's write counter never change it.
-Corollaries that fall out without special cases:
+### 3.1 What compares what
-- `hostbox.Actor` carries `Binding` instead of `Revision`, so `claimBoundIdentity` and `VerifyRegional` go back to plain whole-actor equality and still refuse a box quarantined, readmitted, re-enrolled or moved since startup (fix report concern 1 closes; `sameVerifiedActor` and its ruling 6 pin go).
-- `Revision` keeps its one honest meaning, a signed write counter: CAS for the activation CLI, the loss grant's `+1` scope, the backfill pins, logs.
-- Wake, launch, inventory write and handover all compare the same thing the same way: stored binding == current binding.
+| Comparison | Left | Right |
+|---|---|---|
+| wake, inventory write, launch authorize, serving handover and park, handover recovery, recovery rebind | stored stamp (inventory, fence target, launch record, predecessor) | fresh `actor.Binding` |
+| agent install, census, retirement, stop, generations | stored stamp | the agent's pinned stamp or another stored stamp (record to record) |
+| regional engine, moves, leases, `VerifyRegional` | fresh actor | pinned actor, `sameVerifiedActor` |
+| receipt vs request or target (box) | `receipt.Binding` | stamp |
+| receipt (console, unchanged) | `receipt.DirectoryRevision` numeral | `0 < n <= roster.Revision` |
-Why not A: it is a half fix (every membership write anywhere still strands every instance) and its compatibility story is worse (console-side, so v0.28.4 consoles keep breaking new boxes). Why not C2: it costs a floor gate and a fleet-wide release ordering to keep three numeral comparisons that carried no decision.
+### 3.2 Root's identities (R2)
-Deferred, not blocked by this: the backfill and census pins on `Revision` (hostops/backfill.go:193, backfill_publish.go:169, claimactivation/backfill.go) should pin a membership digest of the whole roster (the same tuple without the per-row part, plus every row) so a hold in flight cannot strand a plan. The dev backfill runs claims-off, so it can wait for its own proposal.
+| Function | Identity | Used by | After quarantine, no restart | After readmission, no restart |
+|---|---|---|---|---|
+| `ClaimRootHTTP.InventoryActor` | fresh `assembly.Identity.Verify` in every mode (change claimassembly.go:382 and rootinventory_startup.go:47) | `commitRootInventoryPending` (rootinventory.go:61), `validateServingHandover` (claimservinghandover.go:25), `rebindRecoveryInventory` (rootrecovery_rebind.go:63) | refuses (`actorMatches`): no new inventory, handover or rebind while quarantined | passes with B1: a request stamped B0 is refused, one stamped B1 is accepted |
+| launch authorize `h.Actor` | already fresh (claimlaunch_production.go:70) | claimlaunch_authority.go:82 | refuses | B0 launch records refused |
+| `cleanupEnrollment.actor` | startup read, `Eligible false`, `Quarantined true`, with `Binding` computed from the same read | `configureSigner` (claim_evidence_wiring.go:60-64: box, enrollment, census key), `actorForConstruction` (claimconstruction.go:187, 229; claimjournal_migration.go:98): the stop coordinator's identity and the producers' fence stamps | stops, retirements and settlements of historical installations keep working: they are record to record (claimstop.go, claimretire_transport.go) and never read a binding against a fresh actor | same; its stamp is B0, so anything it newly stamps is refused by the fresh authority until root restarts (fail closed) |
+| agent pins (`Reconcile.DirectoryRevision`, census) | startup read | installs, local census | n/a (agent) | new installs refuse at root (B0 vs B1) until the agent restarts; installs made before the quarantine are refused for good |
-## 4. Build plan
+So a readmitted box keeps nothing: every installation made before the quarantine is reinstalled, and the agent and root restart to pick up B1. Which is the brief's requirement, stated as a runbook step.
+
+### 3.3 Recovery, rebind and handover (R3)
+
+| Path | file:line | Rev 2 rule | Numeral predecessor |
+|---|---|---|---|
+| recovery rebind | rootrecovery_rebind.go:75 | add `source.DirectoryRevision != actor.Binding` to the `ErrTypedInventory` refusal before any reuse; `recoveryInventory` (:35) then copies an equal value | refused |
+| handover recovery | claimhandover_recovery.go:217 | add `inv.DirectoryRevision != actor.Binding`; the re-stamp at :243 copies an equal value | refused |
+| serving handover | claimservinghandover.go:29-32, claimservingparkroot_linux.go:131, claimservinglegacyroot_linux.go:102 | `prior == actor.Binding` and `next == actor.Binding` | refused |
+| cold handover | hostbox/coldhandover.go:108-114, 122, 141, 268, 336 | unchanged. Authority: the prior's fence receipt (`FenceReceiptFor`, `VerifyReceipt`) and the admitted claim at `next.ETag`. It compares the prior inventory to the prior target record to record, parks the prior under its own stamp (`TypedRetirement` at :268) and starts a successor inventory with one route entry at the fresh binding (:336). It reuses no artifact, so it may cross a binding change | the prior inventory matches its own numeral target (:141), but its receipt's `Binding` is empty and `verifyRetirementReceipt` refuses it: a numeral predecessor cannot be parked through cold handover either |
+
+Every numeral-stamped predecessor is therefore refused on every path (wake, launch, rebind, recovery, serving and cold handover). Nothing converts one. Task 9 establishes that none exists before the roll; if one is found, the roll stops and Paul rules.
-Order matters: 1 and 2 are pure and testable alone; 3 is the box and root rewrite; 4 is the console; 5 is the witness; 6 the census; 7 the roll.
+### 3.4 Deferred
+
+The backfill and census pins on `Revision` (hostops/backfill.go:193, backfill_publish.go:169, claimactivation/backfill.go) still see holds. The dev backfill runs claims-off; a separate proposal can pin a whole-roster membership digest.
+
+## 4. Build plan
| # | Task | Files | Test that pins it |
|---|---|---|---|
-| 1 | `hostactors.BoxBinding(r Roster, ref string) (string, bool)` and `hostactors.ValidBinding(s string) bool`. Frozen v1 tuple, encoded like journalservice.go:184 (an ordered `[]any` with a version tag, JSON-marshalled, sha256, lower hex). A comment in the style of journalservice.go: never extend the tuple; a new field is v2 | hostactors/binding.go | `TestBoxBindingTuple`: a golden vector for a fixed roster; a table that mutates each tuple field and expects a new digest; a table that mutates each excluded field (`Revision`, `Holds`, `Activations`, `EnrollmentAttempts`, `Consoles`, `Regions`, a sibling row, `Role`, `Label`, `Group`, `LossIDs`, `EnrolledAt`) and expects the same digest; an unknown box returns false |
-| 2 | `hostbox.Actor`: drop `Revision`, add `Binding string`; `actorMatches` requires `Binding != ""` | hostbox/identity.go | `TestIdentityVerifyRequiresBinding` (extends the existing `Verify` tests); `TestMoveParksVerifiedIdentityAndRealEngine` "revision" case becomes "binding", and a new "revision" case asserts a roster write with the same binding is accepted |
-| 3 | Box and root: `productionClaimRoster.Actor` and `verifyClaimCleanupEnrollment` compute `Binding` from the roster they read; every stamp and compare site uses `actor.Binding` (claimassembly.go:179-180, 381; claimconstruction.go:327; claimroleassembly.go:58; rootinventory.go:67; rootinventory_state_linux.go:38; claimroleassembly_linux.go:373; claimlaunch_authority.go:82; claimlaunch_root.go:216; claimservinghandover.go:29-32; claimservingparkroot_linux.go:131; claimservingparksource_linux.go:41; claimservinglegacyroot_linux.go:44, 102; claimhandover_recovery.go:224, 243; claimhandover_transport.go:110; claimrecovery_remote.go:54; rootrecovery_rebind.go:68; relocationeffects.go:275; rootexecution_authority.go:79; rootinventory_startup.go:45; claimfilesseed_select.go:38; claimservingpark_transport.go:158). `servingPriorRevision` becomes `prior == actor.Binding`. Delete `sameVerifiedActor`; `VerifyRegional` compares `a != e.actor` again | internal/host | existing suites re-pointed; `TestClaimRegionalEnrollmentSurvivesRosterRevision` kept as is (it is the regional half of the witness); `TestSameVerifiedActorIgnoresOnlyRevision` deleted; `TestServingPriorBindingIsEquality` for the three former `<=` sites |
-| 4 | Console: hostops/evidence.go:123 and wake_reset_transport.go:318 use `ValidBinding` instead of parse-and-bound | internal/hostops | the existing evidence tests gain a "numeral stamp refused, binding accepted" case; `TestVerifyStopEvidenceSurvivesQuarantine`: a receipt stays valid after `Directory.Quarantine` of its box |
-| 5 | Production-wired witness, linux, in internal/host: `release.NewDirStore`, root signer, `hostfloor.Publish`, a one-box roster written through `Directory.Replace`; `productionClaimRoster` + `IdentityProvider.Verify` (the fixtures of claim_regional_revision_test.go:64-98); the real `ReconcileAdapter.Install` + `EmptyInstallationCensus.Initialize` writing a `StopInventory` through the real `JournalService` inventory in a temp dir; then the real comparisons: `ReconcileAdapter.CheckLocal`, `ClaimRoleAssembly.PrepareState` (local path, claimroleassembly_linux.go:373) and `ClaimRootHTTP.validateServingHandover`. Steps: (a) install at binding B0; (b) real `Directory.Reserve`, `ReleaseFinishedHold`, `Reserve(activation=true)`, `ReleaseActivation`, `BeginEnrollmentAttempt`, `SetBoxRole`: `Revision` moves by six, every comparison still passes, `Verify` returns an actor equal to the pinned one; (c) real `Directory.Quarantine`: `Verify` refuses (`ErrChanged`); readmit by `Replace` (State active, as hostresolve/readmit.go:131-136): `Verify` passes, every installed-state comparison refuses (`ErrTypedInventory`); (d) re-enrol: a fresh row with a new `Enrollment` for the same box id: refused; (e) floor and home: `Replace` refuses both after publication (membership.go:241, roster.go:216-217), so the witness writes a signed roster with a new `FloorSHA256`, then one with a new `HomeRegion`, straight to the store as claim_regional_revision_test.go:81-91 does: every installed-state comparison refuses. Mutation checks, run and recorded in the fix report: add `Holds` to the tuple and (b) fails; drop `QuarantineRevision` and (c) passes wrongly; drop `Enrollment` and (d) passes wrongly; restore `<=` in `servingPriorRevision` and the handover step of (c) passes wrongly | internal/host/claim_binding_witness_linux_test.go | `TestClaimBindingSurvivesHoldChurnAndRefusesMembershipChange` |
-| 5b | Root-only comparisons (`commitRootInventoryPending`, `ClaimLaunchRoot.authorize`) run on the dev root runner with the existing `rootrunner` fixtures: the same (b) and (c) through `ClaimRootHTTP` with `InventoryActor` wired to the production actor | internal/host/*_rootrunner_linux_test.go | `TestClaimBindingRootComparisons` |
-| 6 | Census. Plan 14: new overlay `internal/provision/testdata/plan14-root-reads-roster-binding.tsv`, `rev3=PROPOSED-roster-binding`, loaded last; re-pin every root-read unit task 3 touches (the test names them; classes unchanged, no new read: the binding is computed from the roster read that already exists) and `@coverage` for internal/host, internal/hostbox, internal/hostops. 9B8: no record write changes; run `TestPlan9B8RecordWriteCensus` and expect it unchanged. Ruling 6: `BoxBinding` is reached only from `productionClaimRoster.Actor`, `verifyClaimCleanupEnrollment` and the two hostops evidence checks, all claim-mode; extend the module-wide scan in claimstep8_ruling6_test.go (the `checkBackfillDoneCallers` shape) to pin `BoxBinding` callers and drop the `sameVerifiedActor` pin. A claims-off or no-census box never builds a claim assembly, never reads the roster as an actor and never stamps an inventory, so its effects are unchanged. Proposal section "Roster binding" in census-proposal-claim-step8-readiness.md, after "Ack refresh" | provision testdata, host test, notes | `TestPlan14RootReadCensus`, `TestPlan9B8RecordWriteCensus`, `TestStep8CensusChangesReachOnlyClaimMode` |
-| 7 | Roll and check. Dev box (leo) first, then the dev console, then the G10 harness. Before the roll: on each claim box, list root's installed inventories and confirm every `DirectoryRevision` is absent (expected: none on leo). After the roll: a create's hold moves `Revision` and `journalctl` shows no `ErrTypedInventory` or `selected authority changed` on the regional or provision lines; the first install's inventory carries a 64-hex stamp | runbook | harness G10 |
+| 1 | `hostactors.BoxBinding(r Roster, ref string) (string, bool)` and `hostactors.ValidBinding(s string) bool`. Frozen v1 tuple, encoded like journalservice.go:184 (an ordered `[]any` with a version tag, JSON, sha256, lower hex) with the same "never extend" comment | hostactors/binding.go | L0 `TestBoxBindingTuple`: a golden vector for a fixed roster; every tuple field mutated gives a new digest; every excluded field mutated (`Revision`, `Holds`, `Activations`, `EnrollmentAttempts`, `Consoles`, `Regions`, a sibling row, `Role`, `Label`, `Group`, `LossIDs`, `EnrolledAt`) gives the same digest; unknown box returns false |
+| 2 | `hostbox.Actor` gains `Binding`; `actorMatches` also requires `Binding != ""`; the four sanity checks add it | hostbox/identity.go, host sanity sites of 1.2 | L1 `TestIdentityVerifyRequiresBinding`; `TestMoveParksVerifiedIdentityAndRealEngine`: "revision" case now expects acceptance, new "binding" case expects `ErrChanged` |
+| 3 | Box and root stamps and comparisons: `productionClaimRoster.Actor` and `verifyClaimCleanupEnrollment` compute `Binding`; the 22 stamp and compare sites of 1.2 use `actor.Binding`; `servingPriorRevision` becomes equality; `claimBoundIdentity` uses `sameVerifiedActor`; `sameVerifiedActor` keeps ignoring only `Revision` | internal/host, internal/hostbox | L1 `TestSameVerifiedActorIgnoresOnlyRevision` (kept, now walks `Binding` too); `TestClaimRegionalEnrollmentSurvivesRosterRevision` kept; `TestServingPriorBindingIsEquality` |
+| 4 | Receipt contract (1.4): `StopRequest.RosterRevision`, `WritersStoppedRequest.RosterRevision`, `StopReceipt.Binding`; receipt writers and the box-side receipt comparisons; `legacyJournalProofMatch` digests `Binding` | host/claimstop*.go, claimretire_transport.go, claimjournal_proof.go, rootmigration_evidence.go, claimwakestop.go, relocationeffects.go, claimservinglegacy.go | L7a `TestStopReceiptCarriesNumeralAndBinding`: the written receipt has a numeral `directory_revision` equal to the request's roster revision and a 64-hex `binding` equal to the installation's stamp; the box verifiers refuse a receipt whose `binding` differs |
+| 5 | Root identities (3.2): `InventoryActor` = `assembly.Identity.Verify` at claimassembly.go:382 and rootinventory_startup.go:47; cleanup actor unchanged except `Binding` | host/claimassembly.go, rootinventory_startup.go, claimcleanup_identity.go | L4 below |
+| 6 | Recovery (3.3): predecessor checks at rootrecovery_rebind.go:75 and claimhandover_recovery.go:217 | internal/host | L6 below |
+| 7 | Witness tests L2 to L7 (next table) | internal/host | |
+| 8 | Guard: no console or hostops verifier change. Record the empty `git diff v0.28.4..HEAD --stat` for hostops/evidence.go, wake_reset_transport.go, record.go in the fix report | | L7b, L7c |
+| 9 | Pre-roll check for leo (R7), read-only, with the result pasted in the fix report. All of these must be empty or absent, not merely "no running instances": root inventory rows and pending inventory requests in `/var/lib/carlos-claims/journals.db` (the `StopInventoryDB` tables, inventory_expected.go:59 `SnapshotRequest` state, and the launch journal opened at claimjournal_migration.go:121); fence records under `/var/lib/carlos-claims/authority/fences`; serving parks under `/var/lib/carlos-claims/authority/serving-parks`; retirement and handover journals under `/var/lib/carlos-claims/retire/{serving,cold,retired}`; unit bindings and materializations under `/var/lib/carlos-claims/unit-bindings` and `unit-materializations`; restart requests under `/var/lib/carlos-release/private/restarts`; the migration record under `/var/lib/carlos-claims/authority/migration` listing zero items; in the bucket, no `control/hosts/<host>.json` naming leo, no `control/hosts/*/evidence/*/leo/` or `serving-evidence/leo/` objects, and a roster with no holds or activations. Any non-empty item stops the roll | runbook | the G10 harness re-run after the roll |
+| 10 | Census. Plan 14: overlay `internal/provision/testdata/plan14-root-reads-roster-binding.tsv`, `rev3=PROPOSED-roster-binding`, loaded last; re-pin every root-read unit tasks 3 to 6 touch (the test names them; classes unchanged: the binding is computed from the roster read that already exists, and `InventoryActor` moves to a read the assembly already makes) with `@coverage` for internal/host, internal/hostbox. 9B8: no record write changes; `TestPlan9B8RecordWriteCensus` expected unchanged. Ruling 6: `BoxBinding` is reached only from `productionClaimRoster.Actor` and `verifyClaimCleanupEnrollment`; extend the module-wide scan in claimstep8_ruling6_test.go (the `checkBackfillDoneCallers` shape) to pin those callers and `sameVerifiedActor`'s new second caller. A claims-off or no-census box never builds a claim assembly, never computes a binding and never writes a receipt. Proposal section "Roster binding" after "Ack refresh" in census-proposal-claim-step8-readiness.md | provision testdata, host test, notes | `TestPlan14RootReadCensus`, `TestPlan9B8RecordWriteCensus`, `TestStep8CensusChangesReachOnlyClaimMode` |
+| 11 | Roll: leo (box) only; dev console stays v0.28.4; harness G10; then check `journalctl` on leo shows no `ErrTypedInventory` and no `selected authority changed` after the create's hold, and the first install's inventory carries a 64-hex stamp while its receipt (if any) carries a numeral | runbook | |
+
+Witness tests (task 7), all linux, in internal/host, each layer asserting only its own thing. Fixtures: `release.NewDirStore`, root signer, `hostfloor.Publish` with the local `FloorDir` policy written to match (claim_regional_revision_test.go:66-77), a one-box roster written through `Directory.Replace`, `productionClaimRoster`, the real `ClaimAssembly.Build` and `ClaimRootHTTP` wiring from `OpenProductionClaimAssembly` (the ack-refresh test's production wiring), the real `JournalService` inventory in a temp dir. Where a step needs uid 0 (guard root, isolated launch) it runs on the dev root runner under the `rootrunner` tag, with the same assertions.
+
+| Layer | Test | Asserts |
+|---|---|---|
+| L2 no restart, holds | `TestClaimBindingSurvivesRosterWritesWithoutRestart` | install at B0 through the remote path (`ReconcileAdapter.installRemote` -> root `commitRootInventoryPending`); then real `Reserve`, `ReleaseFinishedHold`, `Reserve(activation=true)`, `CancelActivation`, `BeginEnrollmentAttempt`, `SetBoxRole`: `Revision` moves by six; `EmptyInstallationCensus.CheckLocal`, a second inventory write, `prepareStateRemote`, `ClaimLaunchRoot.authorize`, `validateServingHandover` and the regional `RequestStore.Check` all pass; `Verify` returns an actor `sameVerifiedActor` to the pinned one |
+| L3 restart | same, after rebuilding the assembly | every comparison still passes: the restart cannot hide a stale stamp because the stamp is equal |
+| L4 readmission, instance-control (R2) | `TestClaimBindingReadmissionWithoutRestart` through the real instance-control assembly | after `Directory.Quarantine`: `InventoryActor` refuses, a stop of the B0 installation completes (record to record), `configureSigner` still works; after readmission by `Replace`: `InventoryActor` returns B1, a B0 inventory write is refused, a B1 one is accepted, `prepareStateRemote` and `authorize` refuse the B0 installation, the old assembly's new install is refused at root; after restart: a fresh install passes, the B0 installation is still refused |
+| L5 floor and home | `TestClaimBindingFloorAndHomeChange` | rewrite the floor locally and remotely and update `FloorSHA256` by a direct signed write (Replace refuses it after publication), so `productionClaimRoster.Actor` passes its floor check and only the binding differs: installed-state comparisons refuse. Same with `HomeRegion` by direct signed write. Same-reference re-enrolment and census-key rotation likewise by direct signed writes, named as such |
+| L6 recovery (R3) | `TestClaimBindingRecoveryRefusesPredecessor` | rebind and handover recovery refuse a predecessor at B0 after readmission and refuse a numeral predecessor; cold handover parks a B0 predecessor with a matching receipt and starts an empty successor at B1; a numeral predecessor fails `verifyRetirementReceipt` |
+| L7a receipt | task 4 | |
+| L7b purge, mixed version (R1) | `TestPurgeAcceptsC1ReceiptOnUnchangedVerifier` | a receipt written by task 4's code, signed with the box's evidence key, under the op's `evidence/` key; the branch's unchanged `ProductionAuthority.StopBeforeTeardown` and `verifyEvidence` accept it; the same receipt with the binding in `directory_revision` is refused |
+| L7c wake reset, mixed version (R1) | `TestWakeResetAcceptsC1ReceiptOnUnchangedVerifier` | same through `WakeResetTransport.VerifyReceipt` under `serving-evidence/`, including that a quarantined or fenced actor is still refused before the receipt is read |
+
+Mutation checks recorded in the fix report: add `Holds` to the tuple and L2 fails; drop `QuarantineRevision` and L4 passes wrongly; restore `<=` in `servingPriorRevision` and L4's handover step passes wrongly; drop the predecessor check and L6's rebind case passes wrongly; write the binding into `directory_revision` and L7b fails.
-Local tests: changed packages only (hostactors, hostbox, host `-run 'Binding|Regional|MoveParks|Serving|Handover|Identity'`, hostops `-run 'Evidence|WakeReset'`, provision census tests); CI runs the full suite. Go cache at its default.
+Local tests: changed packages only (hostactors, hostbox, host `-run 'Binding|Regional|MoveParks|Serving|Handover|Identity|Receipt|Readmission|Recovery'`, hostops `-run 'Purge.*C1|WakeReset.*C1'`, provision census tests); CI runs the full suite. Go cache at its default.
## 5. Open questions for Paul
-1. Installed inventories under the old stamp. The plan builds no rebind: an inventory, fence target or launch record stamped with a numeral is refused and the instance is reinstalled. Confirm no claim box has an installed inventory today (leo is empty by trial Option B; flagship and the dev console are claims-off). Recommended answer: confirmed, no rebind code.
-2. The tuple. `Role`, `Label`, `Group`, `LossIDs`, `EnrolledAt`, consoles, regions and other boxes are out; `State`, `QuarantineRevision` and `CensusPublicKey` are in. The one judgement call is `Role`: a placement role change leaves installed instances running. Recommended answer: as listed.
-3. The stop-evidence bounds (hostops/evidence.go:124, wake_reset_transport.go:319) become format checks rather than equality with the current binding, so a receipt written before its box was quarantined still verifies, as it does today. Recommended answer: format check; the signature and the record bindings are the authority.
+1. Readmission runbook. Rev 2 makes readmission a clean break: every installation made before the quarantine is refused for good, and the agent and root restart to pick up the new binding. Confirm that is the intended cost of readmission (the brief's "must invalidate" list says so). Recommended answer: yes; reinstall after readmission, restart both services.
+2. Pre-roll check outcome. If task 9 finds any retained inventory, fence, launch, recovery or evidence record on leo, the roll stops and nothing converts it. Recommended answer: stop and rule case by case; expected result is empty.
+3. The stamp in `StopRequest`. Rev 2 adds `RosterRevision` to the box-internal stop and writers-stopped requests so the receipt keeps a numeral without root reading the roster at stop time. Alternative: root fills it from its own fresh read. Recommended answer: the agent supplies it; root copies it; both are the same binary.