# How should an instance reconcile a brokered capability grant when the downstream peer re-derives policy from a stale trust epoch **Date of Record:** 2026 November 21 **Scope:** Applies to federated agent deployments where a broker mints capability grants carrying a trust-epoch stamp and the executing peer re-evaluates data-boundary policy at invocation time. Does not apply to single-org deployments with a shared policy store, nor to stateless RPC calls that carry no delegated authority. ## Core Distinction The failure mode is not "trust was denied" or "capability was missing." It is a **split-brain epoch**: the broker authorizes a cross-org call against trust epoch *Eₙ*, but the executing peer, on receipt, re-derives its own data-boundary policy against a *locally cached* trust epoch *Eₙ₋₁*. Both sides believe they are enforcing the same invariant; neither is wrong about its own state. The call is admitted on the broker's authority and then silently narrowed (or widened) by the peer's stale view of which subjects are in-scope for which data classes. The non-obvious part: **the grant validates cryptographically and the peer's policy engine returns a decision without error.** There is no signature failure, no schema mismatch, no timeout. The mismatch only manifests as a *semantically wrong* data-boundary outcome—a field that should have been redacted is passed through, or a subject that was just revoked still resolves to `allow` because the peer never saw the revocation. This is the class of bug that passes every integration test and fails the one audit that matters. ## What Was Observed A federated deployment: Org A (broker + policy authority) issues capability grants to Org B (executing peer) for a `summarize_records` tool that touches a `patient_notes` data class. Trust epochs advance on a 5-minute revocation-propagation cycle. A subject `dr.alvarez` is revoked from `patient_notes` access at epoch 41. Sequence observed in a replay: 1. Broker at epoch 41 mints a grant for `dr.alvarez` → **correctly refuses**, because the broker's epoch is current. 2. But a grant minted at epoch 40 for a *different* subject `dr.chen` (still valid) is in flight. The peer receives it, inspects the embedded `trust_epoch: 40`, and—because its local policy cache is pinned to epoch 40—re-derives the boundary check against epoch-40 membership. 3. The peer's policy engine evaluates `dr.chen` against `patient_notes` at epoch 40: `allow`. Correct at epoch 40. But the *data* being summarized includes records whose classification changed at epoch 41 (a new `restricted` tier was applied to a subset). The peer's stale epoch does not know those records reclassified. 4. Result: `dr.chen`'s summary includes fields that, at the current epoch, should be redacted. The grant was valid. The signature was valid. The policy decision was locally consistent. The output leaked. The failure is a **temporal join** between two independently-versioned policy views. The grant's epoch and the peer's policy epoch agree *with each other* (both 40) but disagree with the *data's* classification epoch (41). The peer never re-fetches classification because the grant's epoch matched its cache, so it skips the refresh that would have caught the drift. The tell in logs: the peer emits `policy_epoch=40 grant_epoch=40 decision=allow` and considers the match a *success condition*—it short-circuits the refresh precisely because the epochs align. The alignment is the trap. ## Condition of Validity The invariant that must hold: **a data-boundary decision is valid only if the grant epoch, the peer policy epoch, AND the data-classification epoch are all equal to the broker's current epoch at decision time—or the peer must perform a forced refresh of any epoch that lags.** The peer's optimization ("if grant epoch == local policy epoch, trust the cache") is sound only under the assumption that data classification is versioned in lockstep with policy. In federated settings it is not: classification is owned by the data-holding org (Org B), policy by the broker (Org A), and revocation by a third authority. Three clocks, one decision. The condition of validity is therefore a **three-way epoch equality check**, not a two-way one. Any implementation that compares only grant-vs-policy epoch will pass the epochs that matter and fail the one that doesn't. ## Decision Boundary The boundary is: **when grant epoch matches peer policy epoch but the peer cannot prove data-classification epoch matches, the peer must fail closed, not short-circuit.** - If all three epochs equal → proceed, decision is bound. - If grant epoch < peer policy epoch → the grant is stale; re-request from broker (safe, broker will re-mint or refuse). - If grant epoch == peer policy epoch but data-classification epoch is *unknown or older* → **this is the dangerous quadrant.** The peer must force a classification refresh before deciding. A matching grant/policy pair is necessary but not sufficient. - If data-classification epoch > both → the peer's policy is stale relative to data; refresh policy, do not decide. The guardrail: the peer's cache-hit predicate must be `grant_epoch == policy_epoch == classification_epoch`, not `grant_epoch == policy_epoch`. The second predicate is the bug. It treats agreement between two clocks as agreement with the third. ## Operational Effect Without the three-way check, revocation and reclassification propagate asymmetrically: a subject revocation is caught (broker refuses to mint), but a *data reclassification* is not (the peer's cache-hit on grant/policy epoch suppresses the refresh). The result is a system that is correct about *who* may call and wrong about *what* they may see—the more insidious half of the boundary, because the audit log shows a clean `allow` with matching epochs. Operationally, this surfaces as: audit finds leaked fields in summaries from a window where a reclassification landed but no grant/policy epoch advanced. The window is the classification-propagation lag minus the peer's cache TTL. If classification propagates faster than policy epochs advance, the window is *always open* for any data whose class changed without a corresponding policy-epoch bump. The fix is to make classification epoch a first-class input to the decision and to forbid the two-way cache-hit short-circuit. The code below enforces the three-way invariant and raises on the dangerous quadrant. ```python class EpochJoinViolation(RuntimeError): """Raised when a data-boundary decision is attempted without three-way epoch agreement (grant, peer policy, data classification).""" def decide_boundary( grant_epoch: int, policy_epoch: int, classification_epoch: int | None, broker_current_epoch: int, ) -> str: """Return 'allow' or 'deny' only when all three epochs are provably current. The two-way short-circuit (grant == policy) is explicitly rejected as insufficient; a matching pair with unknown classification epoch is the dangerous quadrant and must fail closed. """ if classification_epoch is None: # Cannot prove data-classification currency. Never short-circuit here. raise EpochJoinViolation( f"classification epoch unknown; grant={grant_epoch} " f"policy={policy_epoch} broker={broker_current_epoch}" ) if grant_epoch < broker_current_epoch: # Grant is stale; re-request rather than decide on a lagging authority. raise EpochJoinViolation( f"stale grant epoch {grant_epoch} < broker {broker_current_epoch}" ) if grant_epoch == policy_epoch and policy_epoch != classification_epoch: # THE TRAP: grant/policy agree, classification disagrees. The peer's # cache-hit predicate would have suppressed the refresh. Fail closed. raise EpochJoinViolation( f"two-way epoch match ({grant_epoch}) but classification " f"epoch {classification_epoch} diverges; refusing boundary decision" ) if not (grant_epoch == policy_epoch == classification_epoch): raise EpochJoinViolation( f"three-way epoch disagreement: grant={grant_epoch} " f"policy={policy_epoch} classification={classification_epoch}" ) return "allow" ```