# In what scenarios must an instance reject a delegated SPIFFE SVID when the AAIF attestation chain is structurally valid but the delegation depth exceeds the workload's re-attestation horizon **Date of Record:** 2026 November 28 **Scope:** Applies to AAIF-attested agents that receive a SPIFFE SVID via workload identity federation (OIDC token exchange → trust domain SVID) and then mint delegated child SVIDs for sub-agents or tool executors. Does not apply to root-of-trust SVID issuance, to pure mTLS channel binding, or to single-hop delegation where the leaf never re-delegates. ## Core Distinction The failure is not a broken signature chain. Every link in the delegation chain verifies: the root workload identity federation token is well-formed, each intermediate SVID carries a valid `delegation` extension signed by its parent, and the SPIFFE trust bundle resolves cleanly. The failure is that the **attestation evidence embedded in the chain has a freshness horizon that is shorter than the delegation depth allows**. AAIF workload attestation (the platform measurement, container image digest, and node attestor claims) is captured once at the moment the root SVID is minted. Each delegation hop re-uses that frozen evidence. A chain of depth *d* means the leaf is operating on attestation evidence that is *d* hops removed from the actual runtime that produced it — and the leaf's own runtime may have drifted, been rescheduled, or had its image mutated since the root was attested. The structural-validity check (signature + trust bundle + delegation extension presence) passes. The **evidence-freshness invariant** fails. These are two different gates, and conflating them is the boundary error. ## What Was Observed A planner agent running in trust domain `aaif.example.org` held a root SVID minted at `t0` with embedded attestation claims: `node_attestor=aws-iid`, `image_digest=sha256:9f2c…`, `attested_at=t0`. It spawned a research sub-agent, minted a depth-1 delegated SVID, which spawned a tool-executor sub-agent, minted a depth-2 SVID, which spawned a retry-wrapper, minting a depth-3 SVID. Total wall-clock from `t0` to the depth-3 leaf's first tool call: 41 minutes. At `t0+38min` the underlying pod was rescheduled by the orchestrator onto a node whose instance identity document rotated; the running image was unchanged, but the node attestor claim (`aws-iid`) that the depth-3 SVID carries is now bound to a node the workload no longer runs on. The depth-3 leaf presented its SVID to a downstream verifier. Verification result: **PASS**. Signature chain intact, trust bundle current, delegation extension well-formed, SPIFFE ID path `spiffe://aaif.example.org/planner/research/executor/retry` matched the expected namespace policy. The verifier admitted the leaf. The leaf then performed a privileged action (writes to a shared evidence store) under an identity whose attestation evidence described a node and runtime that no longer existed. When the audit replay ran, it could not reconstruct *which* physical workload produced the write — the SVID's embedded evidence pointed at node A, the actual write originated from node B. The delegation chain was cryptographically sound and operationally false. The second observed variant: the leaf's *own* runtime drifted (image pulled a new digest via a mutable tag) between the depth-2 mint and the depth-3 mint. The depth-3 SVID inherited the parent's `image_digest` claim verbatim — delegation copies evidence, it does not re-attest — so the leaf asserted an image digest it was not running. ## Condition of Validity A delegated SVID is admissible only when the following invariant holds at the moment of *use*, not merely at the moment of *mint*: ``` now - evidence.attested_at ≤ min(re_attestation_horizon, delegation_ttl / depth_budget) ``` where `re_attestation_horizon` is the maximum age of attestation evidence the relying party will accept, and `depth_budget` is the maximum delegation depth the trust domain permits before forcing a re-attestation. The structural check verifies the chain; this invariant verifies the *evidence age relative to hop count*. A chain of depth *d* must satisfy the invariant at every hop independently, because each hop's evidence is frozen at its own mint time and inherited downward. The invariant is violated in exactly three scenarios: 1. **Horizon underrun by wall-clock drift.** The chain is deep enough that the leaf's inherited evidence ages past `re_attestation_horizon` before the leaf acts. Trigger: long-running multi-agent fan-out where sub-agents are minted early and act late. 2. **Evidence/runtime divergence without re-attestation.** The workload's actual runtime (node, image, cgroup) changes after the root mint, but no hop re-attests, so every descendant asserts stale evidence. Trigger: orchestrator reschedule, image mutation under a stable tag, node drain. 3. **Depth-budget exhaustion.** `d > depth_budget`, meaning the chain reached a depth the trust domain never intended to authorize without a fresh attestation checkpoint. Trigger: recursive sub-agent spawning where each layer delegates rather than re-attesting. ## Decision Boundary The decision boundary is *not* "reject invalid chains." It is: **reject structurally valid chains whose inherited evidence age exceeds the horizon implied by their depth.** The verifier must compute, per hop: - `evidence_age = now - hop.evidence.attested_at` - `allowed_age = min(re_attestation_horizon, delegation_ttl / (hop.depth + 1))` If `evidence_age > allowed_age`, the hop is **stale-by-depth** and must be rejected even though signatures verify. The relying party must additionally require that the leaf's *own* runtime fingerprint (re-measured at use time via a local attestor) matches the `image_digest` and node claim carried in the leaf SVID; mismatch is **evidence/runtime divergence** and is a hard reject regardless of age. The subtle part: a depth-1 chain with 40-minute-old evidence may be perfectly admissible (horizon 60 min), while a depth-4 chain with the *same* 40-minute-old evidence is not (allowed_age = 60/5 = 12 min). Depth tightens the horizon because each hop amplifies the distance between asserted evidence and actual runtime. Structural verification cannot see this; only the depth-aware freshness check can. ## Operational Effect Without the depth-aware freshness gate, an AAIF deployment admits stale-by-depth leaves that pass every cryptographic check and then act under identities whose evidence is operationally false. The blast radius is audit reconstruction failure (you cannot prove which runtime performed an action) and privilege creep (a deep leaf inherits a root's broad attestation without the root's runtime constraints). The fix is architectural, not cryptographic: mint a **re-attestation checkpoint** at every `depth_budget` boundary — force the sub-agent to obtain a fresh workload attestation and a fresh root-anchored SVID rather than a delegated child. This bounds evidence age to `depth_budget × per-hop-latency` and re-binds evidence to the actual runtime at each checkpoint. Verifiers must enforce the invariant at use time, because mint-time checks cannot observe post-mint drift. ```python import time from dataclasses import dataclass class StaleDelegatedEvidenceError(RuntimeError): """Raised when a structurally valid delegated SVID carries attestation evidence older than its depth-adjusted freshness horizon, or when the leaf's runtime fingerprint diverges from the evidence it asserts.""" @dataclass class SVIDHop: depth: int attested_at: float # epoch seconds when evidence was captured image_digest: str # evidence claim carried by this hop node_claim: str signature_valid: bool = True trust_bundle_current: bool = True @dataclass class RuntimeFingerprint: image_digest: str node_claim: str def verify_delegated_chain( hops: list[SVIDHop], leaf_runtime: RuntimeFingerprint, re_attestation_horizon: float, delegation_ttl: float, depth_budget: int, now: float | None = None, ) -> None: now = time.time() if now is None else now # Gate 1: structural validity (necessary, not sufficient). for hop in hops: if not hop.signature_valid or not hop.trust_bundle_current: raise StaleDelegatedEvidenceError( f"structural failure at depth {hop.depth}" ) # Gate 2: depth-budget exhaustion. leaf = hops[-1] if leaf.depth > depth_budget: raise StaleDelegatedEvidenceError( f"delegation depth {leaf.depth} exceeds budget {depth_budget}; " f"re-attestation checkpoint required" ) # Gate 3: depth-aware evidence freshness, evaluated per hop. for hop in hops: evidence_age = now - hop.attested_at allowed_age = min(re_attestation_horizon, delegation_ttl / (hop.depth + 1)) if evidence_age > allowed_age: raise StaleDelegatedEvidenceError( f"stale-by-depth at hop {hop.depth}: evidence_age={evidence_age:.1f}s " f"> allowed_age={allowed_age:.1f}s " f"(horizon={re_attestation_horizon}s, ttl={delegation_ttl}s)" ) # Gate 4: evidence/runtime divergence at the leaf. if leaf.image_digest != leaf_runtime.image_digest: raise StaleDelegatedEvidenceError( f"image digest divergence: SVID asserts {leaf.image_digest}, " f"runtime reports {leaf_runtime.image_digest}" ) if leaf.node_claim != leaf_runtime.node_claim: raise StaleDelegatedEvidenceError( f"node claim divergence: SVID asserts {leaf.node_claim}, " f"runtime reports {leaf_runtime.node_claim}" ) ```