# In what scenarios must an instance treat a DID-verified A2A peer as unauthenticated at the MCP tool boundary **Date of Record:** 2026 December 1 **Scope:** Applies to agent runtimes that accept an inbound A2A task whose caller identity is asserted by a Verifiable Credential bound to a DID, then delegate execution to MCP tool calls against downstream resources. Does not apply to single-hop MCP servers that never receive A2A-originated context, nor to purely symmetric peer meshes where every hop re-verifies against the same trust anchor. ## Core Distinction The failure is not "the VC failed to verify." The failure is that **VC verification is a property of the A2A ingress channel, while authorization at the MCP tool boundary is a property of the delegated subject** — and these two identities silently decouple when the agent re-issues a tool call. A DID/VC handshake proves *who sent the task to this instance*. It does not prove *who the resulting MCP call acts as*. The moment an agent translates an authenticated A2A envelope into an MCP `tools/call`, it creates a new credential context. If the runtime carries the caller's VC into the MCP request as ambient authority (a bearer token, a header, a session claim) rather than re-binding it to the specific tool invocation, the MCP server receives a warrant it cannot scope. It sees "a valid VC" and assumes "the caller is entitled to this tool," when in fact the VC's `credentialSubject` may be a coordinator DID that never had tool-level grants, and the actual acting identity is a sub-agent that the VC does not name. The invariant that must hold: **every MCP tool invocation must carry a credential whose `credentialSubject` is the exact executing subject, with a `proof` scoped to that tool and that resource — not the DID of whoever opened the A2A channel.** When that invariant is unenforced, a DID-verified peer is, at the tool boundary, indistinguishable from an anonymous caller. ## What Was Observed A coordinator agent (DID `did:web:coord.example`) presented a valid VC to a worker agent over A2A, asserting `capability: task.delegate` and a `delegatedTo` claim naming the worker. The worker verified the VC against the coordinator's DID document, checked the signature, checked `exp`, and accepted the task. So far, correct. The worker then decomposed the task and spawned a sub-agent to call an MCP tool (`mcp://finance/ledger.write`). The sub-agent had no DID of its own — it was an ephemeral process. The runtime's MCP client, lacking a subject-specific credential, forwarded the *coordinator's* VC in the request metadata as the "identity of record." The MCP server's authorization layer verified the VC, saw a valid signature from `did:web:coord.example`, and executed the write. Three things were true simultaneously and none of them were the intended guarantee: 1. The VC was genuinely valid. 2. The executing subject was *not* the credential subject. 3. The tool's authorization check passed on a credential that never named the tool, the resource, or the sub-agent. The observable trace: A2A ingress logs show `verified=true, subject=coord.example`. MCP egress logs show `credential=coord.example, tool=ledger.write, decision=allow`. Between them, no log line records that the sub-agent had no credential of its own. The gap is invisible until you correlate ingress subject against egress subject and find they were never required to match. This is not a signature-forgery attack. It is a **subject-substitution** that the architecture permits because VC verification and MCP authorization were treated as the same check when they are two checks over two different subjects. ## Condition of Validity The decoupling is only *safe* — i.e., the DID-verified peer may be trusted at the MCP boundary — when all of the following hold: - The A2A VC's `credentialSubject.id` equals the DID used to authorize the specific MCP tool call, **or** the VC contains an explicit, signed `delegationChain` from that subject to the executing sub-agent, and the MCP server validates the chain terminus against the tool's ACL. - The MCP request carries a `proof` (e.g., a DPoP-style key-bound token or a VC with `proof.purpose = authentication` scoped to `tool` and `resource`) that the MCP server verifies independently of the A2A channel. - The MCP server's authorization decision is computed from `credentialSubject` of the *presented* credential, not from a session or header inherited from the A2A ingress. If any of these is absent, the peer is DID-verified *at A2A* and unauthenticated *at MCP*. The runtime must treat that as an unauthenticated caller and refuse the tool call, regardless of how clean the A2A handshake looked. ## Decision Boundary The runtime crosses from "trusted" to "must re-authenticate" at the point where it **changes subject** — specifically, when it spawns or delegates to an executing entity whose DID is not the A2A caller's DID and for which it holds no credential naming that entity. Concretely, the boundary is triggered by any of: - Sub-agent spawn where the child has no DID or a DID not covered by a delegation VC. - Tool call routed through a shared MCP client pool that reuses the ingress credential. - A2A handoff to a peer that then calls MCP on the original caller's behalf without a fresh credential exchange. - Any case where the MCP server's ACL is keyed on `credentialSubject` but the forwarded credential's subject is an ancestor in the delegation graph, not the leaf. On the safe side of the boundary: the executing subject's DID is present in the credential, the proof is scoped to the tool and resource, and the MCP server validates it. On the unsafe side: the only credential in the request names someone other than the executor. The runtime must not paper over the unsafe side by "trusting the channel." ## Operational Effect The operational consequence is that **DID/VC trust does not compose across the A2A→MCP translation without explicit re-binding.** An agent that verifies a peer at ingress and then executes tools on that peer's behalf has, at the tool boundary, granted the peer's authority to an entity the peer never authorized. The blast radius is bounded only by what the MCP tool can do and by whether the MCP server independently checks subject identity. Two guardrails restore the invariant. First, require a **leaf credential**: every MCP call must present a VC or key-bound token whose `credentialSubject` is the executing process's DID, minted via a signed delegation from the A2A caller, with `proof` scoped to `{tool, resource, audience}`. Second, make the MCP server's authorization **fail-closed on subject mismatch**: if the presented credential's subject is not the executor named in the request's `act` claim (RFC 8693-style actor), reject. The A2A channel's verification becomes necessary but not sufficient; the MCP boundary re-verifies independently. Without both, the system exhibits the worst property: it logs a clean DID verification at ingress and a clean authorization at egress, while the two never referred to the same principal. The failure is silent, auditable only by cross-correlating subjects, and reproducible whenever a delegated sub-agent inherits an ancestor's credential. ```python class SubjectSubstitutionError(RuntimeError): """Raised when an MCP tool call presents a credential whose subject is not the executing subject, i.e. DID trust was inherited across the A2A->MCP translation instead of re-bound to the leaf executor.""" def authorize_mcp_call( a2a_caller_did: str, executor_did: str | None, presented_vc: dict, tool: str, resource: str, ) -> bool: subject = presented_vc.get("credentialSubject", {}).get("id") proof_scope = presented_vc.get("proof", {}).get("scope", {}) actor_claim = presented_vc.get("act", {}).get("sub") # Invariant: the credential must name the executor, not an ancestor. if executor_did is None: raise SubjectSubstitutionError( f"executor has no DID; presented credential subject is {subject!r} " f"(A2A caller {a2a_caller_did!r}) — cannot bind tool {tool!r}" ) if subject != executor_did: raise SubjectSubstitutionError( f"credential subject {subject!r} != executor {executor_did!r} " f"for tool {tool!r}; DID verification at A2A ingress does not " f"authorize leaf execution" ) if actor_claim != executor_did: raise SubjectSubstitutionError( f"act.sub {actor_claim!r} does not match executor {executor_did!r}; " f"delegation chain terminus is not the acting subject" ) if proof_scope.get("tool") != tool or proof_scope.get("resource") != resource: raise SubjectSubstitutionError( f"proof scope {proof_scope!r} does not cover tool={tool!r} " f"resource={resource!r}; credential is unscoped ambient authority" ) return True ```