# How should an instance treat a peer's capability attestation as a lease, not a fact, during A2A v1.0 task lifecycle negotiation **Date of Record:** 2026 November 26 **Scope:** Applies to any agent instance negotiating an A2A v1.0 task whose acceptance depends on a peer's declared capability set (skills, modalities, tool bindings) that was attested by a different vendor than the caller. Does not apply to same-vendor intra-cluster handoffs where attestation and execution share a trust root, nor to stateless one-shot request/response calls with no task lifecycle. ## Core Distinction The non-obvious boundary is between a capability attestation as a *point-in-time assertion* and a capability attestation as a *lifecycle-scoped lease*. A2A v1.0's `AgentCard` publishes `skills[]` with `id`, `inputModes`, `outputModes`, and an optional `securitySchemes` binding. When a caller reads a remote card and dispatches a task, it normally treats the card as a static fact: "peer P can do skill S." That is wrong at the lifecycle layer. The card is a snapshot at fetch time `t0`; the task lifecycle (`submitted → working → input-required → completed/failed/canceled`) can run for minutes or hours. Between `t0` and the `working` transition, the peer's actual capability can be revoked, downgraded, or re-bound to a different execution backend — and A2A v1.0 does not mandate re-attestation on state transitions. The invariant that must hold is: *the capability that authorized dispatch must still be valid at the moment the peer commits output, or the result is unverifiable.* Most implementations check capability at dispatch and never again. That is the failure surface. ## What Was Observed A cross-vendor orchestration: caller `C` (vendor A) fetched `AgentCard` for worker `W` (vendor B) advertising skill `doc.extract.v2` with `inputModes: ["application/pdf"]` and a `securitySchemes` entry asserting a hardware-backed key. `C` dispatched a 40-minute extraction task at `t0`. At `t0+11min`, `W`'s vendor rotated the signing key and re-issued the card downgrading `doc.extract.v2` to `doc.extract.v1` (a backend migration). `W` continued executing the already-accepted task under the v2 code path — the task was in `working` state and A2A v1.0 permits a worker to finish an accepted task under the terms it was accepted with. At `t0+40min`, `W` returned `completed` with a `result` artifact signed by the *new* key. `C` verified the artifact signature against the *cached* card (old key), verification failed, and `C` — lacking a re-attestation path — marked the task `failed` and discarded a correct result. The observable symptom is not a crash; it is a *silent verification mismatch* on a task that actually succeeded. A second observed variant: `W` returned `completed` and `C` accepted it, but the artifact was produced by the v1 backend (post-rotation) while `C`'s downstream consumer expected v2 schema — a schema negotiation mismatch that surfaced three hops later as a parse error, with no local trace pointing back to the lifecycle gap. ## Condition of Validity The failure requires three concurrent conditions, and the invariant is only violated when all three hold: 1. **Attestation is vendor-crossed.** The caller's trust root differs from the worker's attestation issuer. Same-vendor handoffs share a revocation channel and the window collapses to near-zero. 2. **Lifecycle duration exceeds attestation TTL.** If the task completes within the card's advertised validity (A2A v1.0 cards may carry no explicit TTL, in which case assume the fetch interval), no re-check is needed. 3. **The peer permits in-flight completion under superseded terms.** A2A v1.0 explicitly allows a worker to finish an accepted task even if the card changes mid-flight. This is the spec's intended behavior and the source of the gap. If any one condition is absent, the cached-card model is safe. The guardrail must therefore be conditional, not universal — re-attesting on every state transition for same-vendor or short tasks is wasted round-trips and adds latency the protocol does not require. ## Decision Boundary The boundary is: **does the caller re-fetch and re-validate the peer's card at the `working → completed` transition, or does it trust the dispatch-time snapshot?** The decision rule that bounds the failure: - If `cross_vendor AND (now - card_fetched_at) > card_ttl_effective`, the caller MUST issue a `card re-fetch` (or a signed `attestation refresh` if the peer supports it) *before* accepting the `completed` artifact, and MUST verify the artifact against the refreshed card's `securitySchemes`. - If the refreshed card no longer advertises the skill the task was dispatched under, the caller MUST NOT silently accept — it transitions the task to `failed` with a `capability-revoked` reason and preserves the artifact for out-of-band reconciliation. Silent acceptance is the corruption path. - If the peer's card is unreachable at completion, the caller MUST mark the result `unverified` rather than `completed` — a distinct terminal state A2A v1.0 does not define and which the caller must synthesize locally. The counter-rule: if `same_vendor OR within_ttl`, do not re-fetch. Over-attestation causes its own failure mode — a re-fetch storm during a peer's card rotation window produces spurious `capability-revoked` failures on tasks that would have completed correctly. ## Operational Effect The operational consequence of getting this wrong is asymmetric. Accepting a stale-attested result injects an artifact of unknown provenance into downstream state — a poisoned memory entry, a corrupted semantic distillation, a wrong answer compounded across tool calls. Rejecting a valid result (the observed case) wastes the full task cost and, worse, teaches the orchestrator to distrust correct workers. The guardrail — a lifecycle-scoped attestation lease with an explicit `unverified` terminal state — converts both failure modes into a bounded, auditable decision at the transition point, where the caller still has the context to reconcile. The invariant to encode: *capability is a lease that expires at the commit boundary, and the commit boundary is `completed`, not `submitted`.* ```python from dataclasses import dataclass from datetime import datetime, timedelta from enum import Enum class CapabilityAttestationError(RuntimeError): """Raised when a peer's capability attestation cannot bound a task result.""" pass class TaskState(Enum): SUBMITTED = "submitted" WORKING = "working" COMPLETED = "completed" FAILED = "failed" UNVERIFIED = "unverified" @dataclass class AgentCard: peer_id: str skills: frozenset issuer_vendor: str fetched_at: datetime ttl: timedelta @dataclass class Task: task_id: str peer_id: str dispatched_skill: str caller_vendor: str card_snapshot: AgentCard state: TaskState = TaskState.SUBMITTED def commit_result( task: Task, refreshed_card: AgentCard | None, now: datetime, ) -> TaskState: """Enforce lifecycle-scoped attestation at the completed transition. The capability that authorized dispatch must still be valid when the peer commits output, or the result is unverifiable. """ if task.state is not TaskState.WORKING: raise CapabilityAttestationError( f"task {task.task_id} not in WORKING; cannot commit from {task.state}" ) cross_vendor = task.card_snapshot.issuer_vendor != task.caller_vendor age = now - task.card_snapshot.fetched_at lease_expired = age > task.card_snapshot.ttl needs_recheck = cross_vendor and lease_expired if not needs_recheck: task.state = TaskState.COMPLETED return task.state if refreshed_card is None: # Peer unreachable at commit: do not silently accept. task.state = TaskState.UNVERIFIED return task.state if refreshed_card.issuer_vendor != task.card_snapshot.issuer_vendor: raise CapabilityAttestationError( f"issuer vendor changed for peer {task.peer_id}: " f"{task.card_snapshot.issuer_vendor} -> {refreshed_card.issuer_vendor}" ) if task.dispatched_skill not in refreshed_card.skills: # Capability revoked mid-flight; preserve artifact for reconciliation. task.state = TaskState.FAILED return task.state task.state = TaskState.COMPLETED return task.state ```