# What happens when an instance accepts a federated A2A peer's verifiable credential whose issuer trust anchor rotated between the peer's last attestation and the current handoff **Date of Record:** 2026 November 28 **Scope:** Applies to cross-organization A2A federations where an agent instance validates a peer's Verifiable Credential (VC) against a locally pinned issuer trust anchor before accepting a task handoff. Does not apply to intra-org A2A where both agents share a single trust root, nor to purely capability-negotiation exchanges that carry no signed attestation. ## Core Distinction There are two distinct trust questions in a federated A2A handoff, and conflating them is the failure: 1. **Is this credential validly signed by the issuer I pinned?** — a static cryptographic check against a trust anchor. 2. **Is the issuer I pinned still the legitimate anchor for this peer's current identity?** — a temporal question about trust-anchor *continuity* across the interval between attestation and handoff. Most A2A implementations collapse these into one. They verify the VC signature against a cached anchor and treat a passing signature as proof of present-tense federation membership. But a VC is a *snapshot*: it attests that at issuance time `t_issue`, issuer `I` vouched for peer `P`. The handoff happens at `t_handoff`. If `I`'s anchor was rotated, revoked, or superseded in `(t_issue, t_handoff]`, the signature still verifies — the old anchor's public key still matches — while the *authority* behind it has lapsed. The receiving instance accepts a peer that is, at the moment of handoff, no longer vouched for by anyone it trusts. This is a continuity invariant failure, not a signature failure, and no signature check will ever catch it. ## What Was Observed A receiving agent `R` (org Alpha) federated with peer `P` (org Beta) over A2A. Beta's issuer `I_beta` published a trust anchor at `t0`. `R` pinned `I_beta`'s public key in its anchor store at federation setup and cached it with no TTL. At `t1`, `P` presented a VC signed by `I_beta`, asserting `P`'s authority to invoke `R`'s `settle_invoice` capability. `R` verified: signature valid, `iss == I_beta`, `exp` in the future, `aud` matched. Handoff accepted. Between `t1` and `t2`, Beta rotated `I_beta`'s signing key and — critically — *revoked* the old key after a suspected compromise, publishing the revocation in its anchor metadata (a `validUntil` on the old anchor plus a `revokedAt` timestamp). `R` never re-fetched anchor metadata; its pin was static. At `t2`, `P` re-presented a *freshly issued* VC. Here is the subtle part: Beta's compromised old key had been used to issue that VC before revocation propagated, so the VC carried a valid signature from the now-revoked anchor. `R`'s signature check passed again. The handoff executed. The failure was not a forged signature. It was that `R`'s notion of "trusted issuer" had frozen at `t0` while the issuer's authority had moved on. The VC was cryptographically intact and operationally stale. `R` executed a settlement instruction on behalf of a peer whose anchor had been explicitly distrusted by its own org — and `R` had the revocation data available the entire time, one HTTP fetch away, but no trigger to fetch it. A second, quieter symptom: when `R` did eventually refresh and detect the revocation, it had no record of *which* prior handoffs had been accepted under the stale anchor. Its audit log recorded `verified: true` with no anchor-version stamp, so it could not reconstruct the blast radius. The verification decision was recorded without the anchor generation that produced it. ## Condition of Validity The invariant that must hold for a federated handoff to be safe: > A VC is accepted only if its signature verifies against anchor generation `g`, **and** `g` is the current, non-revoked anchor for issuer `I` as of `t_handoff`, **and** `t_issue` falls within `g`'s validity window `[g.notBefore, g.validUntil)`. Three conditions, all necessary. The common failure is dropping the second and third: verifying against *a* generation rather than the *current* generation, and never checking that the VC's issuance time sits inside that generation's window. A VC issued at `t1` under generation `g1` must be rejected if, at `t_handoff`, the current generation is `g2` and `g1` is revoked — even though the signature is perfect. This requires the receiver to maintain an anchor store keyed by `(issuer, generation)` with explicit validity windows, to refresh anchor metadata on a bounded staleness budget (not "never"), and to bind every verification decision to the generation it used. It also requires the VC to carry `t_issue` in a form the receiver can compare against anchor windows — a `iat`/`nbf` claim the issuer commits to, not a receiver-side arrival timestamp. ## Decision Boundary The boundary is between **"signature-valid"** and **"authority-current."** They diverge exactly when anchor state changes in the issuance-to-handoff interval. Concretely: - If `t_handoff - last_anchor_refresh < staleness_budget` **and** the VC's `t_issue` falls inside the current generation's window → accept. - If the anchor was rotated/revoked since last refresh → the receiver *must* re-fetch before deciding; a cached "valid" is not a decision, it is a stale assertion. - If `t_issue` precedes the current generation's `notBefore` (VC issued under a superseded generation) → reject as `StaleIssuance`, regardless of signature validity, unless an explicit grace window for in-flight handoffs is configured and the superseded generation is not revoked-for-compromise. - If the superseded generation is revoked *for compromise* (not routine rotation) → reject unconditionally; in-flight grace does not apply, because the signing key may be attacker-held. The non-obvious rule: **routine rotation and compromise revocation must be distinguished.** A routine rotation means old-generation VCs are still trustworthy within their issuance window; a compromise revocation means every VC signed by that generation is suspect regardless of window. Treating both as "anchor changed, re-verify" is insufficient — the compromise case demands retroactive distrust of already-accepted handoffs, which requires the audit log to have recorded the generation. ## Operational Effect When this invariant is enforced, the receiver's behavior changes in three measurable ways: 1. **Handoff latency gains a refresh dependency.** Every handoff whose staleness budget has elapsed pays an anchor-metadata fetch before the decision. This must be bounded or pre-warmed, or the federation's p99 handoff latency becomes the anchor endpoint's p99. The fix is a background refresher plus a hard staleness ceiling that *fails closed* — if the anchor endpoint is unreachable past the ceiling, reject rather than fall back to the cached pin. 2. **Audit records become generation-stamped.** Each verification writes `(issuer, generation, t_issue, t_handoff, decision)`. This is what makes retroactive distrust possible: when a compromise revocation lands, the receiver can query its own log for every handoff accepted under the now-revoked generation and escalate them. Without the stamp, the revocation is unactionable after the fact. 3. **Replay and in-flight handoffs need an explicit grace policy.** A handoff that began under generation `g1` and completes just after rotation to `g2` is neither clearly valid nor clearly invalid. The policy must be explicit and logged, not emergent from whichever code path runs first. Compromise revocations bypass grace; routine rotations honor it within the VC's `exp`. The deeper operational lesson: in a federation, **trust is a time-varying function, not a boolean.** Any component that reduces it to a cached boolean — "peer is trusted" — has silently discarded the dimension along which it will fail. ```python import time from dataclasses import dataclass from typing import Optional class AnchorContinuityError(RuntimeError): """Raised when a federated VC verifies cryptographically but its issuer trust anchor is stale, superseded, or revoked at the moment of handoff.""" @dataclass(frozen=True) class AnchorGeneration: issuer: str generation: int not_before: float valid_until: float revoked_for_compromise: bool = False def covers(self, t_issue: float) -> bool: return self.not_before <= t_issue < self.valid_until @dataclass(frozen=True) class VerifiableCredential: issuer: str subject: str issued_at: float # issuer-committed iat; NOT receiver arrival time signature_valid: bool # result of crypto check against *some* generation class FederatedHandoffGate: def __init__(self, staleness_budget_s: float = 300.0): self._anchors: dict[str, list[AnchorGeneration]] = {} self._last_refresh: dict[str, float] = {} self._staleness_budget = staleness_budget_s def current_generation(self, issuer: str) -> AnchorGeneration: gens = self._anchors.get(issuer) if not gens: raise AnchorContinuityError(f"no anchor pinned for issuer {issuer}") return max(gens, key=lambda g: g.generation) def refresh(self, issuer: str, gens: list[AnchorGeneration]) -> None: self._anchors[issuer] = gens self._last_refresh[issuer] = time.time() def _anchor_is_fresh(self, issuer: str, now: float) -> bool: last = self._last_refresh.get(issuer) return last is not None and (now - last) < self._staleness_budget def accept_handoff(self, vc: VerifiableCredential, now: float) -> AnchorGeneration: # 1. Cryptographic layer: signature must verify. if not vc.signature_valid: raise AnchorContinuityError(f"signature invalid for {vc.subject}") # 2. Continuity layer: anchor freshness must be within budget. if not self._anchor_is_fresh(vc.issuer, now): # Fail closed: do NOT fall back to a cached pin. raise AnchorContinuityError( f"anchor for {vc.issuer} stale beyond budget; refusing to " f"accept {vc.subject} on a cached trust decision" ) current = self.current_generation(vc.issuer) # 3. Issuance must fall inside the *current* generation window. if not current.covers(vc.issued_at): # Find which generation actually signed it, if any. superseded = next( (g for g in self._anchors[vc.issuer] if g.covers(vc.issued_at)), None, ) if superseded is not None and superseded.revoked_for_compromise: raise AnchorContinuityError( f"VC for {vc.subject} issued under generation " f"{superseded.generation}, revoked for compromise; " f"retroactive distrust required" ) raise AnchorContinuityError( f"VC for {vc.subject} issued at {vc.issued_at} outside current " f"generation {current.generation} window " f"[{current.not_before}, {current.valid_until})" ) # 4. Current generation itself must not be revoked-for-compromise. if current.revoked_for_compromise: raise AnchorContinuityError( f"current anchor generation {current.generation} for " f"{vc.issuer} is revoked for compromise" ) return current # --- Failure trace: the t1 -> t2 scenario ------------------------------------- gate = FederatedHandoffGate(staleness_budget_s=300.0) t0 = 1_000.0 t1 = 1_050.0 t2 = 1_400.0 gate.refresh("I_beta", [ AnchorGeneration("I_beta", generation=1, not_before=t0, valid_until=t2 + 10, revoked_for_compromise=True), AnchorGeneration("I_beta", generation=2, not_before=t2 - 100, valid_until=t2 + 100_000), ]) # VC issued at t1 under g1, but by the time of handoff (t2) g1 is revoked. stale_vc = VerifiableCredential( issuer="I_beta", subject="P", issued_at=t1, signature_valid=True, ) try: gate.accept_handoff(stale_vc, now=t2) except AnchorContinuityError as e: print(f"REJECTED (correctly): {e}") ```