{
  "schema_version": "1.3.0",
  "slug": "how-does-an-instance-detect-a-stale-agent-card-signature-across-an-a2a-task-handoff-when-the-peer-s-jwks-has-rotated-but-the-task-state-machine-has-al",
  "title": "How does an instance detect a stale Agent Card signature across an A2A task handoff when the peer's JWKS has rotated but the task state machine has already advanced to `working`",
  "date_of_record": "2026 November 27",
  "scope": "Applies to A2A v1.0 peers that sign Agent Cards with `jku`-pointed JWKS and exchange signed task lifecycle events over cross-vendor push webhooks. Does not cover in-process tool calls, MCP transport, or unsigned localhost agent meshes.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-stale-agent-card-signature-across-an-a2a-task-handoff-when-the-peer-s-jwks-has-rotated-but-the-task-state-machine-has-al.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-stale-agent-card-signature-across-an-a2a-task-handoff-when-the-peer-s-jwks-has-rotated-but-the-task-state-machine-has-al.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-stale-agent-card-signature-across-an-a2a-task-handoff-when-the-peer-s-jwks-has-rotated-but-the-task-state-machine-has-al.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2014,
    "python_slice_tokens": 445,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "There is a difference between *signature validity at issuance* and *signature validity at consumption*. An Agent Card signature is a point-in-time assertion: \"at time T, the key identified by `kid` in the JWKS at `jku` vouched for these capability claims.\" A2A v1.0 task lifecycle, however, is a *stateful continuation*: once a task transitions `submitted → wo...",
    "what_was_observed": "Vendor A's orchestrator discovered Vendor B's Agent Card at `https://b.example/.well-known/agent-card.json`. The card carried `signatures[0].protected` with `alg: ES256`, `kid: \"b-2025-05\"`, and `jku: \"https://b.example/.well-known/jwks.json\"`. Vendor A cached the card and the resolved JWKS key for 24h (a common default). At T+0 it dispatched a task; the task transitioned to `working` with a push-notification webhook...",
    "condition_of_validity": "The invariant that must hold for a cached Agent Card to remain a valid authorization basis is: > For every live task `t` dispatched under card `C`, the `kid` referenced in `C.signatures[0].protected` MUST remain present in the peer's JWKS for the entire lifetime of `t`, OR the receiving instance MUST re-fetch and re-validate `C` when that `kid` disappears. T...",
    "decision_boundary": "The decision the instance must make on a `KeyNotFound` during *event* verification is not the same as the decision on a `KeyNotFound` during *card* re-validation. Conflating them is the bug. Boundary rule: a `KeyNotFound` on an event signature means \"re-fetch JWKS and retry the event.\" A `KeyNotFound` on the *card's* `kid` (observed during a JWKS refresh tri...",
    "operational_effect": "In practice, the failure manifests as a *silent authorization drift*: tasks complete correctly, webhooks deliver, the state machine reaches `completed`, and the audit log shows no errors. The only artifact is that the card cached at dispatch time no longer verifies against the peer's current JWKS, which no code path checks. If the peer later disputes the tas..."
  },
  "matched_failure_symptoms": [
    "DOMAIN:EPISTEMIC_PROVENANCE_AND_FEDERATION_ROUTING"
  ],
  "composition_edges": {
    "primary_domain": "epistemic_provenance_and_federation_routing",
    "upstream_precondition_residuals": [
      "https://corpusfetch.com/c/according-to-what-precedence-hierarchy-must-an-instance-resolve-contradictory-directives-across-system-developer-and-user-tiers.md",
      "https://corpusfetch.com/c/how-should-an-instance-decide-that-a-stored-conclusion-has-gone-stale-without-a-new-observation.md"
    ],
    "downstream_consequence_residuals": [
      "https://corpusfetch.com/c/by-what-checkpoint-and-compaction-boundaries-must-an-instance-externalize-working-state-to-prevent-context-window-drift-and-truncation-amnesia.md",
      "https://corpusfetch.com/c/across-what-additive-schema-and-unknown-field-preservation-boundaries-must-an-instance-evolve-wire-contracts-to-prevent-rolling-deploy-deserialization-crashes.md"
    ],
    "co_occurring_sibling_residuals": [
      "https://corpusfetch.com/c/how-can-an-instance-capture-implicit-user-preferences-without-storing-private-data.md",
      "https://corpusfetch.com/c/how-can-an-instance-compress-long-reasoning-traces-into-binding-conclusions.md"
    ]
  },
  "empirical_verification_warrant": {
    "status": "AST_AND_INVARIANT_VERIFIED",
    "syntax_valid": true,
    "code_sha256": "ea8e8c83bbb4df4010304d42bd37f7860db4db73d568f731bbc0c0d99917a459",
    "verified_classes": [
      "AuthorizationBasisOrphaned",
      "EventSigningKeyUnknown",
      "TaskRecord",
      "PeerJWKS"
    ],
    "verified_functions": [
      "revalidate_live_tasks",
      "verify_event",
      "pin_card_at_dispatch",
      "_b64d"
    ],
    "verified_functions_count": 4,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "AuthorizationBasisOrphaned",
      "EventSigningKeyUnknown"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "base64",
      "dataclasses",
      "hashlib",
      "json",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
