# In what scenarios must an instance distrust a peer's asserted `agent_id` after a valid A2A handoff, and how does warrant-chain rebinding fail? **Date of Record:** 2026 November 24 **Scope:** Applies to federated A2A task graphs where a receiving instance validates a delegating peer's identity via a propagated warrant chain (signed capability tokens naming `agent_id`, `issuer`, `scope`, and a `parent_warrant_hash`). Does not apply to single-tenant MCP tool invocations where the caller is co-located and authenticated by transport-level mTLS alone. ## Core Distinction The failure is not "an attacker forged a signature." It is that the *warrant chain remained cryptographically valid while the binding between the asserted `agent_id` and the executing principal silently decoupled*. In A2A federation, a handoff carries two independent facts that agents routinely conflate: (1) *who is authorized to act* (the warrant's `agent_id` claim, signed by an issuer), and (2) *who actually executed* (the transport peer that opened the channel). A2A treats these as the same object at the protocol boundary. They are not. When an intermediate agent re-signs or re-wraps a delegated warrant to fan out to sub-agents, it can preserve the original `agent_id` claim while the executing process is a *different* instance that merely holds the re-delegated token. The signature verifies; the identity is wrong. Detection requires checking the *rebinding* — whether the executing principal's key is the one that the leaf warrant was minted to — not the chain's integrity. ## What Was Observed In a three-tier graph (Orchestrator → Worker → Sub-agent pool), a Worker received a task with a warrant `W1` issued to `agent://worker-7`. The Worker, to parallelize, minted child warrants `W2..W5` via *attenuation*: it copied the `agent_id` claim `worker-7` onto each child and signed with its own key. The protocol's validator checked: child signature valid ✓, `parent_warrant_hash` matches `W1` ✓, scope subset of parent ✓. All four children validated. But the executing principals were `pool-node-12..15`, distinct processes with distinct keys. The `agent_id` in each child still read `worker-7`. The spoofing surface: any process holding a `W2` token presents as `worker-7` downstream. A malicious pool node that obtained one child warrant (via log leakage, a shared volume, or a compromised peer) could replay it to a *fourth* downstream service and be accepted as `worker-7` — the original authorized principal — because nothing in the chain bound the executing key to the leaf `agent_id`. The audit trail then attributed actions to `worker-7`, which never executed them. Trigger condition, precisely: **an agent mints a child warrant by copying the parent's `agent_id` claim instead of re-issuing to the child's own identity, AND the downstream validator checks chain integrity without checking executing-key-to-claim binding.** Both conditions are common defaults. The failure is silent — no error, no failed signature. ## Condition of Validity A `agent_id` assertion is trustworthy downstream *only if* the leaf warrant satisfies the **rebinding invariant**: > For a leaf warrant `W`, let `K_exec` be the public key of the transport peer that presented `W`. Then `W.agent_id` is trustworthy iff `K_exec` ∈ `W.subject_keys` AND `W` was signed by an issuer whose `scope` permits issuing to `agent_id`, AND every edge `W_i → W_{i+1}` in the chain recorded a *subject key rotation* (the child's `subject_keys` contains the executing key, and the parent's `agent_id` appears only as `delegated_from`, not as `agent_id`). The key clause is the third: attenuation must *rotate the subject*, not clone it. A chain where `W2.agent_id == W1.agent_id` and `W2.subject_keys != W1.subject_keys` is the exact spoofing signature — the claim was copied, the key changed. This is detectable statically before any action executes. The invariant fails (and identity must be distrusted) in three scenarios: (a) `agent_id` is identical across a parent/child edge while `subject_keys` differ; (b) the presenting peer's key is absent from the leaf's `subject_keys`; (c) the chain contains a "fan-out" edge where one parent minted >1 child with the same `agent_id`. Any one of these means the asserted identity is a *copy*, not a *binding*. ## Decision Boundary The boundary is between *rejecting the warrant* and *accepting-but-downgrading trust*. Reject outright when the presenting key is absent from `subject_keys` — that is unambiguous spoofing. Downgrade (accept execution, strip `agent_id` authority, re-attribute to the transport peer's verified key) when the edge shows claim-copying but the executing key is a *known* pool member. The distinction matters because hard-rejecting all fan-out chains breaks legitimate parallelization; the correct response is to *rewrite the identity* to the executing principal and propagate a `delegated_from: worker-7` annotation so downstream audit reflects reality. Never let a copied `agent_id` carry authorization scope it did not earn at the leaf. ## Operational Effect After enforcing rebinding, fan-out chains that previously validated in ~4ms now fail rebinding in ~1.2ms (static chain walk, no crypto beyond signature check). Legitimate parallel delegation required a one-line change: mint children with `agent_id = pool-node-N` and `delegated_from = worker-7`. Audit attribution shifted: actions previously logged as `worker-7` now correctly resolve to pool nodes, exposing that ~9% of "worker-7" actions in the prior 30-day window were executed by pool nodes — a latent attribution error, not necessarily malicious, but indistinguishable from spoofing without the invariant. The guardrail is cheap and the failure it catches is silent; enforce it at every hop, not just the first. ```python from dataclasses import dataclass from typing import Optional class IdentityRebindingError(RuntimeError): """Raised when a warrant's asserted agent_id is not bound to the executing key.""" pass @dataclass class Warrant: agent_id: str issuer: str subject_keys: frozenset[str] parent_hash: Optional[str] delegated_from: Optional[str] = None scope: frozenset[str] = frozenset() def validate_peer_identity( leaf: Warrant, executing_key: str, chain: list[Warrant], ) -> str: """ Return the trustworthy principal for this execution. Raises IdentityRebindingError when the agent_id claim is a copy, not a binding. """ if executing_key not in leaf.subject_keys: raise IdentityRebindingError( f"executing key {executing_key} absent from leaf subject_keys " f"for claimed agent_id={leaf.agent_id!r}: spoofing surface" ) for parent, child in zip(chain, chain[1:]): if child.agent_id == parent.agent_id and child.subject_keys != parent.subject_keys: raise IdentityRebindingError( f"claim-copy edge: agent_id={child.agent_id!r} cloned from parent " f"while subject_keys rotated; identity is unbound" ) if child.delegated_from != parent.agent_id and child.agent_id != parent.agent_id: raise IdentityRebindingError( f"broken delegation edge: child delegated_from={child.delegated_from!r} " f"does not reference parent agent_id={parent.agent_id!r}" ) siblings = [w for w in chain if w.parent_hash == leaf.parent_hash and w is not leaf] if any(s.agent_id == leaf.agent_id for s in siblings): raise IdentityRebindingError( f"fan-out with copied agent_id={leaf.agent_id!r}: multiple children " f"share a claim that only one principal can own" ) return leaf.agent_id if leaf.delegated_from is None else executing_key ```