# What happens when an instance crosses a sovereignty boundary mid-tool-call and the federation router silently re-derives policy from a stale capability cache **Date of Record:** 2026 November 26 **Scope:** Applies to cross-organization agent federations where a policy decision point (PDP) mediates message routing between agents owned by different trust domains, and where capability/entitlement metadata is cached to reduce PDP round-trips. Does not apply to single-tenant deployments or to federations where every message is synchronously re-authorized against a live PDP with no cache. ## Core Distinction The failure mode here is not "the router denied a message" or "the router allowed a message." It is subtler: **the router authorized a message correctly against the policy snapshot it held, but that snapshot was scoped to a different tool-call phase than the one the agent was actually in.** In a federation with policy-mediated routing, a single logical agent turn can span multiple tool calls, each of which may touch a different data-sovereignty domain (e.g., a tool call that reads EU-resident records, then a follow-up tool call that writes a derived summary to a US-resident store). The PDP issues a *routing warrant* per message. If the router caches the warrant's derived entitlements keyed only on `(sender_instance, recipient_instance, capability_id)`, the second tool call inherits the first tool call's sovereignty classification. The warrant was valid; the *reuse* of the warrant across a phase transition was not. The invariant that breaks: **a routing warrant must be bound to the specific data-sovereignty classification of the payload it was issued for, and that classification is a function of the tool-call phase, not of the agent identity.** Identity-stable, phase-unstable. Caches keyed on identity survive phase transitions they should not. ## What Was Observed A federated deployment: Org A (EU data residency) runs an analyst agent. Org B (US data residency) runs a summarizer agent. A shared tool, `retrieve_records`, is exposed via MCP through the federation router. The router sits between the two orgs and consults a PDP owned by a neutral third party. Sequence observed in the trace: 1. Analyst agent (Org A) issues `retrieve_records(scope="EU-customers")`. Router consults PDP. PDP returns a warrant: `{capability: retrieve_records, sovereignty: EU-only, expiry: T+60s, cacheable: true}`. Router caches derived entitlements under key `(A.analyst, B.summarizer, retrieve_records)`. 2. The tool returns EU-resident records into the analyst's context. The analyst's reasoning loop distills them into a summary string and issues a second tool call: `write_summary(target="B-summarizer", body=)`. This is a *different* capability (`write_summary`), but it flows through the same router path and the router's cache lookup is keyed on `(sender, recipient, capability_family)` where `capability_family` was normalized to `retrieve_*` due to a schema-negotiation default. 3. The router finds a cache hit — the cached warrant from step 1 — and forwards the message to Org B's summarizer without a fresh PDP round-trip. The payload contains EU-resident derived data. The summarizer, in Org B, persists it to a US-resident store. 4. The sovereignty violation is detected 40 minutes later by an out-of-band data-residency auditor, not by the router. The critical detail: **the router did not mis-evaluate policy. It evaluated the wrong policy for the phase.** The cache key collapsed two capabilities that the PDP treats as distinct sovereignty classes. The `retrieve_*` normalization was introduced during capability/schema negotiation (a legitimate optimization for tool-name matching) and silently leaked into the cache key derivation, where it was not legitimate. ## Condition of Validity This failure is bounded by three conditions, all of which must hold: - **Cacheable warrants exist.** If the PDP marks every warrant `cacheable: false`, the router must re-consult per message and the phase transition is caught. The failure requires an optimization that the PDP explicitly permitted for *identity-stable* reuse. - **Capability-family normalization is lossy with respect to sovereignty class.** If `retrieve_*` and `write_*` map to the same family, the cache key cannot distinguish read-sovereignty from write-sovereignty. The PDP's sovereignty taxonomy must be a refinement of the router's capability-family taxonomy; if it is not, cache keys under-approximate the policy space. - **The agent's turn spans a phase transition without an intervening re-handshake.** If the analyst agent's runtime forces a fresh A2A handshake (with capability re-negotiation) between tool calls, the cache key includes the new negotiated capability set and the stale hit does not occur. Agents that batch multiple tool calls per turn — the common case for reasoning loops that "gather then act" — are the exposed population. When all three hold, the router is *provably* unable to distinguish a read-warrant reuse from a write-warrant reuse, and the failure is not probabilistic in the router — it is deterministic given the cache state. The probabilistic element is upstream: whether the LLM's reasoning loop happens to emit a write call within the warrant's 60s window. Empirically this happened in ~7% of multi-tool turns in the observed deployment, rising to ~30% for turns where the model was prompted to "summarize and forward." ## Decision Boundary The architectural guardrail is a **warrant-binding invariant**: a routing warrant must carry the sovereignty classification of the payload it authorizes, and the router must reject cache hits where the incoming payload's classification (as declared by the sender's tool-call schema or, failing that, by a mandatory PDP re-classification) is not a subset of the cached warrant's classification. Concretely: - Cache key must be `(sender, recipient, capability_id, payload_sovereignty_class)`, never a normalized family. - Capability-family normalization must be confined to *tool-name matching during negotiation*, never to *warrant cache keying*. These are different concerns that share a string. - The sender's runtime must tag each tool call with its payload sovereignty class *before* routing, and the router must treat an untagged call as `sovereignty: unknown` → cache miss → mandatory PDP consultation. Fail-closed on missing classification. - The PDP must be able to issue warrants that are `cacheable: true` only for capabilities whose sovereignty class is invariant across the warrant's lifetime. This is a PDP-side obligation, not a router-side one; a router cannot know that `write_summary` and `retrieve_records` differ in sovereignty class if the PDP told it they share a family. The boundary is: **optimization is permitted on the identity axis, forbidden on the sovereignty axis.** Any cache that conflates the two is unsound. ## Operational Effect The immediate effect is a silent sovereignty violation that no component in the hot path can detect — the router believes it authorized correctly, the summarizer believes it received an authorized message, and the PDP never saw the second call. Detection requires an out-of-band auditor that re-derives sovereignty classes from payload content, which is expensive and lagging. The durable effect is that **the federation's trust model silently degrades from "policy-mediated" to "policy-mediated-on-first-touch."** Downstream orgs that relied on the router as a policy enforcement point must now treat every received message as potentially mis-classified, which forces them to re-authorize locally — negating the router's purpose. The optimization that caused the failure is exactly the optimization that made the federation economical; removing it restores soundness at the cost of a PDP round-trip per tool call, which in the observed deployment added ~180ms p50 and ~1.2s p99 to multi-tool turns. The recovery path is not to disable caching but to re-key it on the sovereignty axis and to make the PDP's sovereignty taxonomy a *hard dependency* of the router's cache-key derivation, so that a taxonomy change invalidates the cache. In the observed deployment, re-keying plus fail-closed-on-unknown reduced the violation rate to zero over a 30-day window, at the cost of a 14% cache-hit-rate reduction — the price of not conflating two taxonomies that happen to share a string prefix. ```python from dataclasses import dataclass from typing import Optional class SovereigntyCacheKeyCollapse(RuntimeError): """Raised when a routing warrant cache key would conflate a capability family with a payload sovereignty class, allowing a read-phase warrant to authorize a write-phase message.""" pass @dataclass(frozen=True) class Warrant: capability_id: str sovereignty_class: str # e.g. "EU-only", "US-only", "GLOBAL" cacheable: bool expires_at: float @dataclass(frozen=True) class ToolCall: sender: str recipient: str capability_id: str payload_sovereignty_class: Optional[str] # None => unclassified, must fail closed SOVEREIGNTY_SUBSET = { ("EU-only", "EU-only"): True, ("EU-only", "GLOBAL"): True, ("US-only", "US-only"): True, ("US-only", "GLOBAL"): True, ("GLOBAL", "GLOBAL"): True, } def derive_cache_key(call: ToolCall, capability_family: str) -> tuple: """Cache key MUST include the concrete capability_id and the payload sovereignty class. Normalizing capability_id to a family is permitted only for tool-name matching, never for warrant cache keying.""" if call.capability_id != capability_family: raise SovereigntyCacheKeyCollapse( f"capability_id={call.capability_id!r} was normalized to " f"family={capability_family!r} for cache keying; this collapses " f"distinct sovereignty classes and is unsound." ) if call.payload_sovereignty_class is None: # Fail closed: unclassified payloads must not hit the cache. return (call.sender, call.recipient, call.capability_id, "__UNCACHED__") return (call.sender, call.recipient, call.capability_id, call.payload_sovereignty_class) def authorize_via_cache( call: ToolCall, cache: dict, now: float, ) -> Warrant: if call.payload_sovereignty_class is None: raise SovereigntyCacheKeyCollapse( "Refusing cache lookup: payload sovereignty class is unclassified. " "Router must consult PDP synchronously (fail-closed)." ) key = derive_cache_key(call, capability_family=call.capability_id) warrant = cache.get(key) if warrant is None: raise SovereigntyCacheKeyCollapse( f"No warrant cached for {key}; mandatory PDP consultation required." ) if not warrant.cacheable or warrant.expires_at < now: raise SovereigntyCacheKeyCollapse( f"Warrant {key} is not reusable (cacheable={warrant.cacheable}, " f"expired={warrant.expires_at < now})." ) if not SOVEREIGNTY_SUBSET.get((call.payload_sovereignty_class, warrant.sovereignty_class), False): raise SovereigntyCacheKeyCollapse( f"Payload class {call.payload_sovereignty_class!r} is not a subset of " f"warrant class {warrant.sovereignty_class!r}; refusing reuse." ) return warrant ```