# Which invariants prevent stale delegated warrants from resurrecting revoked agent identity across federated trust boundaries **Date of Record:** 2026 November 23 **Scope:** Applies to federated agent deployments where a delegated warrant (capability token, signed delegation chain, or MCP/A2A identity assertion) is minted by an issuer in one trust domain and presented to a verifier in another, with credential rotation or revocation occurring between mint and presentation. Does not cover single-domain token refresh or purely symmetric-key session management. ## Core Distinction The failure surface here is not "revocation doesn't propagate." Propagation is a solved transport problem: publish a revocation list, gossip a CRL, push a status endpoint. The non-obvious boundary is the *temporal interleaving* between three independently-clocked events across organizational trust boundaries: 1. **Mint time** — issuer `I` signs a delegated warrant `W` granting agent `A` a capability, possibly with a delegation chain `I → D → A` where `D` is an intermediate delegate in a third domain. 2. **Rotation/revocation time** — `I` rotates `A`'s credential (new key `k'`) or revokes the delegation chain, invalidating `k`. 3. **Verification time** — verifier `V` in domain `V_dom` checks `W` against `A`'s presented key. The resurrection bug: `V` validates `W`'s signature chain and checks the *presented* key against `W`'s subject binding, but does not confirm that the presented key is the *current* key for that subject at verification time. A revoked `k` paired with a still-valid `W` (which has its own `exp`, hours out) passes every signature check. The warrant outlives the credential it names. ## What Was Observed A three-domain federation: `IssuerDomain` mints warrants, `DelegateDomain` hosts an intermediate agent `D` that re-delegates to worker agents, `VerifierDomain` runs resource servers. Warrants carry `exp = mint + 6h`. Credential rotation runs on a 1h cycle for high-value agents. Trace of a resurrection: - `t=0`: `I` mints `W(A, cap=write, exp=t+6h)`, binding subject to public key `k_A`. - `t=0`: `A` presents `W` to `V`, succeeds. `V` caches the validated `(subject, key, warrant)` triple in a local authorization cache with TTL 5m. - `t=30m`: `A`'s key is compromised; ops revoke `k_A` and rotate to `k_A'`. Revocation event published to `IssuerDomain`'s status endpoint. `D` (DelegateDomain) does **not** subscribe to `IssuerDomain` status — it only validates signatures at delegation time. - `t=45m`: attacker presents `W` with `k_A` to `V`. `V` checks: signature chain valid (yes — `W` was genuinely minted), `W.exp` not passed (yes — 5h15m remaining), subject binding matches presented key (yes — `W` names `k_A`). Cache miss (5m TTL expired). Full revalidation passes. **Write capability granted to a revoked key.** - `t=50m`: legitimate `A` with `k_A'` presents a *new* warrant `W'`; `V` now has two valid-looking subjects for the same logical agent identity, one of which is revoked. The invariant that failed: `V` treated "warrant signature valid ∧ subject binding match" as sufficient for authorization. It is not, when the subject binding can reference a superseded key and the warrant's lifetime exceeds the rotation cycle. ## Condition of Validity The resurrection is bounded only when the verifier enforces a **key-currency check as a conjunct**, not a disjunct, of warrant validation: ``` authorize(W, presented_key, subject) ⟺ sig_chain_valid(W) ∧ W.exp > now ∧ binding_matches(W, presented_key) ∧ current_key(subject, at=now) == presented_key ∧ # ← the missing conjunct not revoked(W.delegation_chain, at=now) ``` Two structural conditions make the conjunct enforceable: - **Warrant lifetime ≤ rotation cycle.** If `W.exp - mint` exceeds the rotation period, a warrant can outlive the key it names. The safe bound is `W.exp ≤ next_rotation(subject)`, or the warrant must carry a `key_version` field that the verifier resolves against the issuer's current key registry. - **Revocation is checked at verification, not at mint.** A delegation chain `I → D → A` is only as fresh as `D`'s most recent status sync. If `D` does not subscribe to `I`'s revocation feed, `D` will re-delegate a revoked capability. The invariant must hold at the *last* hop (`V`), and `V` must independently resolve the full chain's revocation status — not trust `D`'s assertion that the chain was valid when `D` signed. ## Decision Boundary The boundary is sharp: **a warrant is an assertion about a capability, not about a credential's liveness.** Conflating the two is the bug. The decision rule: - If `W`'s subject binding is to a *key identifier* (e.g., `did:key`, JWK thumbprint) and `W.exp` exceeds the rotation cycle → **must** perform key-currency resolution at `V`. Signature validity is necessary, not sufficient. - If `W`'s subject binding is to a *stable identity* (e.g., a DID with a key-rotation log, or an issuer-resolved `sub` with versioned keys) and `V` resolves the current key from the issuer's registry → the conjunct is satisfied by construction, provided the registry read is not stale beyond a bounded skew. - If `W` carries an explicit `key_version` and `V` rejects on version mismatch → resurrection is structurally impossible, at the cost of forcing re-mint on every rotation. The failure mode appears precisely when the deployment chooses the *first* option (key-identifier binding, long warrant TTL) for performance reasons and omits the key-currency conjunct for the same reason. The optimization is the vulnerability. ## Operational Effect Downstream consequences of an unpatched resurrection: - **Audit divergence.** The verifier's logs show a valid, signature-checked authorization. The issuer's revocation log shows the key was dead 15 minutes prior. Post-incident reconciliation fails because no single record is wrong — the *join* is wrong. - **Delegation-chain amplification.** In `I → D → A`, if `D` cached its delegation decision, a single resurrected warrant at `D` can fan out to every worker `D` re-delegated to. Revocation at `I` does not reach `D`'s downstream. - **Rotation-cycle coupling.** Shortening the rotation cycle to reduce the window increases re-mint load on `I` and cache churn at `V`; lengthening it widens the resurrection window linearly. The two knobs are coupled and must be set together, not independently. The guardrail is a single enforced invariant at the verifier: *no authorization decision without a fresh key-currency resolution for the warrant's subject, bounded by a maximum staleness skew.* Everything else — CRL transport, gossip, status endpoints — is plumbing that serves that invariant. ```python import time from dataclasses import dataclass, field class WarrantResurrectionError(RuntimeError): """Raised when a warrant validates but names a superseded/revoked key.""" pass @dataclass class Warrant: subject: str key_id: str capability: str minted_at: float expires_at: float delegation_chain: tuple = () @dataclass class KeyRegistry: # subject -> (current_key_id, rotated_at) current: dict = field(default_factory=dict) revoked_key_ids: set = field(default_factory=set) def resolve_current_key(self, subject: str) -> str: entry = self.current.get(subject) if entry is None: raise WarrantResurrectionError(f"no key registered for subject {subject!r}") return entry[0] def authorize( warrant: Warrant, presented_key_id: str, registry: KeyRegistry, now: float | None = None, max_registry_skew_s: float = 30.0, ) -> bool: now = time.time() if now is None else now # 1. Temporal validity of the warrant itself. if not (warrant.minted_at <= now < warrant.expires_at): raise WarrantResurrectionError( f"warrant for {warrant.subject!r} outside validity window" ) # 2. Subject binding must match the presented key. if warrant.key_id != presented_key_id: raise WarrantResurrectionError( f"presented key {presented_key_id!r} does not match warrant binding " f"{warrant.key_id!r}" ) # 3. THE MISSING CONJUNCT: key-currency resolution at verification time. if presented_key_id in registry.revoked_key_ids: raise WarrantResurrectionError( f"key {presented_key_id!r} for subject {warrant.subject!r} is revoked; " f"warrant is a stale delegation and must not authorize" ) current_key = registry.resolve_current_key(warrant.subject) if current_key != presented_key_id: raise WarrantResurrectionError( f"key {presented_key_id!r} is superseded by {current_key!r} for " f"subject {warrant.subject!r}; re-mint required" ) # 4. Delegation-chain revocation must be resolved at the last hop. for hop_key in warrant.delegation_chain: if hop_key in registry.revoked_key_ids: raise WarrantResurrectionError( f"delegation hop {hop_key!r} revoked in chain for " f"{warrant.subject!r}" ) return True def demo_resurrection(): reg = KeyRegistry() reg.current["agent:worker-7"] = ("key-v1", 0.0) t0 = 1_000_000.0 w = Warrant( subject="agent:worker-7", key_id="key-v1", capability="write", minted_at=t0, expires_at=t0 + 6 * 3600, delegation_chain=("delegate:mid-3",), ) # Rotation: v1 revoked, v2 current. reg.revoked_key_ids.add("key-v1") reg.current["agent:worker-7"] = ("key-v2", t0 + 1800) # Attacker replays the old warrant with the revoked key. try: authorize(w, presented_key_id="key-v1", registry=reg, now=t0 + 2700) except WarrantResurrectionError as e: print(f"BLOCKED (correct): {e}") # Legitimate holder with rotated key presents a fresh warrant. w2 = Warrant( subject="agent:worker-7", key_id="key-v2", capability="write", minted_at=t0 + 1800, expires_at=t0 + 1800 + 3600, delegation_chain=("delegate:mid-3",), ) assert authorize(w2, presented_key_id="key-v2", registry=reg, now=t0 + 2700) print("ALLOWED (correct): rotated key with fresh warrant") if __name__ == "__main__": demo_resurrection() ```