# Where must an instance's vote be rejected when its plan-commitment quorum certificate is internally consistent but references a superseded epoch? **Date of Record:** 2026 November 23 **Scope:** Applies to BFT-consensus-backed multi-agent plan commitment where agents sign epoch-tagged plan digests and quorum certificates (QCs) are verified as `f+1`-of-`2f+1` threshold signatures over `(plan_digest, epoch)`. Does NOT apply to leaderless CRDT merge schemes or single-writer plan registries without epoch fencing. ## Core Distinction The failure this record isolates is *not* forged signatures, equivocating leaders, or threshold shortfalls. It is the **internally valid but epoch-stale quorum certificate**: a QC whose signature set is genuinely produced by `f+1` distinct, authorized agent keys over a plan digest that was legitimately committed in epoch `E-1`, then presented during epoch `E` as if it authorized the plan's continuation. Every cryptographic check passes. The threshold check passes. The digest matches the plan the presenting agent actually intends to execute. What fails is the *liveness-safety coupling*: the epoch field is treated as metadata rather than as part of the signed commitment domain, so a certificate that was valid authority in the past is accepted as authority in the present after the agent set has rotated and the plan's preconditions have silently changed. The distinction that matters operationally: a Byzantine agent does not need to break cryptography to resurrect a dead plan. It only needs to replay a QC across an epoch boundary where the verifier checks *who signed* and *what they signed* but not *when the signing authority was live*. ## What Was Observed A six-agent plan committee (`n=6`, `f=1`, threshold `4`) committed plan `P` with digest `d_P` in epoch `E-1` under agent set `S_{E-1} = {a1..a6}`. The QC `QC_{E-1}(d_P)` contained signatures from `{a1, a2, a3, a4}`. Epoch `E` rotated membership: `a2` and `a3` were evicted for sustained equivocation, replaced by `a7`, `a8`, yielding `S_E = {a1, a4, a5, a6, a7, a8}`. During epoch `E`, agent `a1` resumed execution of `P` (a multi-step tool plan whose step 3 depended on a resource lease held by `a2`). `a1` presented `QC_{E-1}(d_P)` to the plan gate. The gate verified: (i) four signatures, (ii) all keys present in `S_{E-1}`, (iii) digest equals `d_P`, (iv) threshold `4 ≥ f+1`. All true. The gate admitted `P`. The failure trace: 1. `a1` re-enters step 3 with a stale lease assumption; `a2`'s eviction had already revoked the lease in epoch `E`. 2. Step 3 tool call returns a *soft* denial (HTTP 409 with retry hint) rather than a hard error — the plan's error classifier treats 409 as transient. 3. `a1` retries step 3 three times, each consuming a token budget slice, then proceeds to step 4 under the assumption step 3 "eventually succeeded" (the classifier's fallback). 4. Step 4 writes to shared state a value derived from a lease that no longer exists, producing a plan-state divergence visible to `a4` and `a7`. 5. `a4` and `a7`, both honest, each hold different local views of `P`'s progress and begin independent reconciliation attempts, spending an additional 2 epochs of consensus rounds before a human operator halts the swarm. The proximate cause was not the stale QC alone; it was that the *epoch was not in the signed domain*. Had the QC been over `(d_P, E-1)` and the gate required `QC.epoch == current_epoch`, the gate would have rejected `a1` at admission, and `a1` would have been forced to re-propose `P` under `S_E`, which would have failed quorum because `a2`'s lease could not be re-attested by the new membership — surfacing the precondition loss *before* execution rather than four steps in. ## Condition of Validity The guardrail holds only under the following conditions, and each is a real constraint: - **Epoch is inside the signature domain.** The signed message must be `H(d_P ‖ E)`, not `H(d_P)` with `E` as a side-channel field. If `E` is not signed, a Byzantine relayer can rewrite it; if it is signed but not *checked against current epoch*, the replay window stays open. - **Epoch monotonicity is enforced at the verifier, not the proposer.** The verifier must reject any QC with `QC.epoch < current_epoch` outright, with no "grace window." Grace windows reintroduce the replay surface for exactly the duration of the window. - **Quorum intersection across epochs is computed, not assumed.** With `n=6, f=1`, `S_{E-1} ∩ S_E = {a1, a4, a5, a6}` — four agents, which is `≥ f+1` but *not* `≥ 2f+1`. This means an epoch-`E-1` QC and an epoch-`E` QC need not intersect in a way that forces consistency. The invariant is not "old QCs are safe because quorums overlap"; it is "old QCs are unsafe precisely because quorums may not overlap enough to force the old plan's preconditions to be re-attested." - **Precondition re-attestation is part of plan commitment, not plan execution.** If the plan's resource leases are attested outside the QC, epoch rotation cannot invalidate them, and the gate's admission check is incomplete regardless of epoch fencing. ## Decision Boundary The boundary is between two rejection semantics: - **Reject-on-epoch-mismatch (strict):** any QC with `QC.epoch != current_epoch` is rejected at admission. Cost: plans in flight during rotation must be re-proposed, which can fail quorum and surface precondition loss — this is the *desired* behavior. Latency cost is one extra consensus round per rotation boundary. - **Reject-on-precondition-mismatch (semantic):** accept stale-epoch QCs but require the plan's precondition set to be re-attested under current epoch. Cost: the precondition set must be enumerable and signed, which is often not true for plans with implicit dependencies (file handles, leases, external service sessions). The decision rule: **if the plan's precondition set is not fully enumerable and signed, strict epoch rejection is mandatory.** Semantic rejection is only sound when every precondition is itself a signed, epoch-tagged attestation. In the observed incident, the lease was held by `a2` outside the plan's signed precondition set, so semantic rejection would have admitted `P` and failed identically — the strict rule was the only correct boundary. A secondary boundary: the gate must distinguish `QC.epoch < current_epoch` (stale, reject) from `QC.epoch > current_epoch` (future, reject as malformed — this indicates either clock skew across agents or a Byzantine agent attempting to pre-commit). Both rejections are hard; neither is a retryable condition at the plan layer. ## Operational Effect After applying strict epoch fencing and moving `E` into the signed domain, the same rotation scenario produced: - `a1`'s replay of `QC_{E-1}(d_P)` was rejected at admission with `StaleQuorumEpoch`. - `a1` re-proposed `P` under `S_E`; quorum failed at `3/4` because `a2`'s lease could not be re-attested by any current member. - The plan was correctly marked `PRECONDITION_LOST` and escalated to the planner *before* any tool call executed. - Token cost of the failed re-proposal: ~1,200 tokens. Token cost of the original four-step divergence: ~47,000 tokens plus two epochs of reconciliation rounds. The generalizable operational lesson: **a quorum certificate is a statement about authority at a time, not about validity of a plan.** Any verifier that treats the QC as a bearer token for the plan rather than as a time-indexed authorization will admit resurrected plans across membership rotation. The epoch must be inside the signature, checked against current state, and the plan's preconditions must be inside the signed domain — otherwise the gate verifies the wrong proposition. ```python import hashlib from dataclasses import dataclass class StaleQuorumEpoch(RuntimeError): """Raised when a quorum certificate's signed epoch does not match the verifier's current epoch, or when the QC's epoch is not inside the signed message domain (making replay across rotations undetectable).""" pass @dataclass(frozen=True) class QuorumCertificate: plan_digest: bytes epoch: int signers: frozenset[str] signatures: tuple[bytes, ...] signed_message: bytes # MUST be H(plan_digest || epoch), not H(plan_digest) def verify_qc_for_admission( qc: QuorumCertificate, current_epoch: int, authorized_keys: frozenset[str], threshold: int, ) -> None: # Invariant 1: epoch must be inside the signed domain. expected_msg = hashlib.sha256( qc.plan_digest + qc.epoch.to_bytes(8, "big") ).digest() if qc.signed_message != expected_msg: raise StaleQuorumEpoch( f"QC signed domain does not bind epoch {qc.epoch}; " f"replay across rotations is undetectable" ) # Invariant 2: strict epoch equality, no grace window. if qc.epoch != current_epoch: direction = "stale" if qc.epoch < current_epoch else "future" raise StaleQuorumEpoch( f"{direction} QC: signed epoch {qc.epoch} != current {current_epoch}" ) # Invariant 3: threshold over distinct authorized signers. distinct = qc.signers & authorized_keys if len(distinct) < threshold: raise StaleQuorumEpoch( f"insufficient authorized signers: {len(distinct)} < {threshold}" ) def admit_plan_resume( qc: QuorumCertificate, current_epoch: int, authorized_keys: frozenset[str], threshold: int, ) -> str: verify_qc_for_admission(qc, current_epoch, authorized_keys, threshold) return "ADMITTED" ```