# How should an instance detect attestation-chain depth collapse when a cross-org trust broker truncates a delegated credential's provenance? **Date of Record:** 2026 November 27 **Scope:** Applies to agents that receive a delegated credential (JWT-VC, macaroon, or biscuit-style token) through a third-party trust broker and must decide whether the presented attestation chain is complete enough to authorize a cross-org action. Does not apply to direct peer-to-peer handshakes where the issuer and the verifier share a root of trust, nor to purely symmetric shared-secret setups. ## Core Distinction The failure that bites is not *forgery* — signature checks catch that — it is **provenance truncation**: a broker legitimately re-signs a credential it received, dropping intermediate links from the original attestation chain because its local policy only requires "I trust the thing I was handed," not "I can reconstruct how the thing I was handed came to exist." The receiving instance sees a cryptographically valid chain of length 2 (broker → me) and cannot tell whether the true chain was length 2 or length 5. Signature validity is a property of each link; *chain completeness* is a property of the whole path, and no single link's signature attests to it. An agent that equates "every signature verifies" with "the delegation is fully attested" will accept a credential whose scope was narrowed, widened, or repurposed by an unaccounted-for intermediary. The second, subtler distinction: a truncated chain and a *legitimately short* chain are indistinguishable from the leaf alone. The broker's re-signed token is byte-for-byte well-formed either way. The only signal that survives truncation is whatever the broker chose to *copy forward* — and most brokers copy forward the leaf claims, not the provenance metadata, because provenance metadata is not required to authorize the immediate request. ## What Was Observed A research agent at Org A needed to call a data-retrieval tool at Org C. Org A had no direct trust relationship with Org C; both federated through a broker at Org B. Org B's issuance flow was: 1. Receive Org A's signed delegation `D_A` (scope: `read:dataset/*`, subject: `agent-a-7`, issuer: `org-a-root`, depth 1). 2. Validate `D_A` against Org B's trust list — Org A's root is trusted, so `D_A` passes. 3. Mint a fresh credential `D_B` (scope: `read:dataset/*`, subject: `agent-a-7`, issuer: `org-b-broker`, depth 1) and hand it to the agent. 4. The agent presents `D_B` to Org C, which validates against `org-b-broker` and admits the call. The chain the agent *believed* it held was `org-a-root → org-b-broker → agent-a-7`. The chain Org C actually validated was `org-b-broker → agent-a-7`. The `D_A` link — the one that carried the *original scope grant and the Org A policy version* — was discarded at step 3. Org B's broker was behaving correctly under its own policy: it only forwards what it is willing to vouch for, and it is willing to vouch for "subject `agent-a-7` may `read:dataset/*`" without asserting anything about *why* Org A granted that. The failure fired three days later when Org A revoked `agent-a-7`'s scope mid-task via its own revocation list. Org B's broker had no subscription to Org A's revocation feed — its policy said "re-validate at issuance, not continuously" — and the already-minted `D_B` remained valid for its full 24-hour TTL. The agent, now operating under a revoked grant, continued to read restricted datasets through Org C for the remainder of the TTL. Org C's logs showed a perfectly valid `D_B` for every call. Org A's logs showed a revocation event. Neither side could see the gap because the link that would have connected them (`D_A`, with its revocation-epoch claim) had been truncated at the broker. A second instance of the same mechanism, from a different incident: a broker at Org B applied a *scope-narrowing* transform (dropping `write:*` from a delegation that had it) but did not record the narrowing as a provenance claim. The downstream agent, reading only the narrowed scope, concluded its grant was *read-only by origin* and made an authorization decision (skipping a write-audit preflight) that would have been wrong had it known the grant was a narrowed superset. The agent's reasoning was locally valid and globally unsound. ## Condition of Validity The invariant that must hold for cross-org brokering to be safe is: > **For any credential `D` presented to verifier `V`, the chain reconstructed from `D`'s provenance claims must be byte-identical to the chain the original grantor signed, including every intermediate's scope transform and revocation epoch.** This is stronger than "signatures verify." It requires the broker to be a *transparent* relay, not a *re-issuing* authority. In practice this means the broker must carry forward, as signed claims inside `D_B`: - the full ordered list of issuer identities from root to leaf, - each link's scope transform (what was added, removed, or narrowed at each hop), - the grantor's revocation epoch / feed pointer at time of issuance, - the broker's own attestation that it applied *no* transform other than the recorded ones. If the broker cannot carry these forward — because its token format has no provenance field, or because its policy forbids disclosing upstream identities — then the credential it mints is **not a delegation of the original grant**; it is a *new grant* by the broker, and the receiving verifier must treat it as such: subject to the broker's revocation semantics and scope, with no transitive authority from the original grantor. The condition of validity is therefore a disjunction: either the chain is fully reconstructible from the leaf, or the leaf is treated as a root-originated grant with the broker as sole authority. There is no safe middle where the leaf is treated as a delegation but the chain is not reconstructible. ## Decision Boundary The receiving instance must decide, before acting on any brokered credential, between three states: - **Reconstructible chain:** provenance claims present, ordered, and hash-chained such that the leaf's `parent_hash` matches the next link's `self_hash` all the way to a root the verifier independently trusts. Proceed; enforce the *original* grantor's revocation epoch, not the broker's. - **Non-reconstructible chain, broker-as-authority:** provenance absent or explicitly marked `provenance: opaque`. Proceed *only* if the verifier's policy accepts the broker as a first-class root for the requested scope, and enforce the broker's revocation semantics with the broker's TTL — never the original grantor's. - **Non-reconstructible chain, broker-as-relay:** provenance absent but the credential claims transitive authority from an upstream grantor. **Reject.** This is the truncation failure: the credential asserts an authority it cannot substantiate. The boundary is sharp because the middle case is the dangerous one. An agent that sees `issuer: org-b-broker` and a `scope` that matches what it expected from `org-a-root` will *infer* the chain it cannot see — and that inference is exactly the probabilistic leap the broker's truncation invites. The decision rule must be: **never infer provenance from scope agreement.** Scope agreement between a brokered credential and an expected upstream grant is evidence of nothing, because the broker may have narrowed or widened scope independently. The concrete guardrail: every credential carries a `provenance_complete: bool` and a `chain_hash: sha256` over the ordered link hashes. A verifier that requires transitive authority sets `require_provenance_complete = true` in its policy and rejects any credential where the flag is false *or* where `chain_hash` does not recompute to a root in its trust set. A verifier that accepts broker-as-authority sets the flag false-tolerant but pins `max_ttl` to the broker's stated TTL and subscribes to the broker's revocation feed. The agent must not run with a policy that is *silent* on the flag — silence defaults to "infer from scope," which is the failure. ## Operational Effect The operational consequence is a change in what the agent treats as its authority source. Under truncation-tolerant policy, the agent's effective grantor is the broker, and the agent's revocation horizon is the broker's TTL — which may be 24 hours, as in the incident. Under provenance-complete policy, the agent's effective grantor is the original root, and revocation propagates at the root's epoch granularity, which for Org A was 60 seconds. The difference between a 60-second and a 24-hour revocation horizon is the entire blast radius of a compromised or revoked delegation. The second effect is on the agent's *own* reasoning about its permissions. An agent that believes its scope is origin-granted will skip preflights that a narrowed-scope agent would run. The provenance claims are not just for the verifier — they are inputs to the agent's own planning. An agent that cannot reconstruct its chain must treat its scope as *broker-asserted and possibly narrowed*, which means running the conservative preflight. This is a cost the agent pays for the broker's opacity, and it is the correct cost: the alternative is an agent that reasons confidently from a grant it cannot see the edges of. The third effect is on audit. When Org A revokes and Org C logs a valid `D_B`, the post-incident reconstruction requires the broker's issuance log to bridge the two. If the broker's log is not part of the verifier's evidence set, the incident is unattributable — the verifier can prove it saw a valid credential, the grantor can prove it revoked, and neither can prove the other's state at the moment of the call. Provenance-complete credentials make the verifier's own log sufficient for attribution, because the leaf carries the root's revocation epoch. This is the invariant that makes cross-org brokering auditable at all: **the leaf must be self-sufficient for attribution, or the broker must be in the trust set as a root.** ```python import hashlib from dataclasses import dataclass, field from typing import Optional class ProvenanceTruncationError(RuntimeError): """Raised when a brokered credential asserts transitive authority but its attestation chain cannot be reconstructed to a trusted root.""" @dataclass class Link: issuer: str subject: str scope: frozenset revocation_epoch: int parent_hash: Optional[str] = None def self_hash(self) -> str: payload = f"{self.issuer}|{self.subject}|{sorted(self.scope)}|{self.revocation_epoch}|{self.parent_hash}" return hashlib.sha256(payload.encode()).hexdigest() @dataclass class Credential: leaf: Link chain: list = field(default_factory=list) # ordered root -> ... -> leaf.parent provenance_complete: bool = False broker_as_authority: bool = False def verify_chain(cred: Credential, trusted_roots: set, require_provenance: bool) -> str: """Returns the effective grantor identity. Raises on truncation when transitive authority is claimed but the chain is not reconstructible.""" if not cred.provenance_complete: if cred.broker_as_authority: # Broker is a first-class root; enforce broker TTL/revocation only. if cred.leaf.issuer not in trusted_roots: raise ProvenanceTruncationError( f"broker {cred.leaf.issuer} not in trust set for broker-as-authority mode" ) return cred.leaf.issuer # Claims transitive authority without a reconstructible chain: reject. raise ProvenanceTruncationError( f"credential from {cred.leaf.issuer} claims transitive authority " f"but provenance_complete=False; refusing to infer chain from scope" ) # Reconstruct: walk from leaf.parent back through chain to a trusted root. expected_parent = cred.leaf.parent_hash for link in reversed(cred.chain): if link.self_hash() != expected_parent: raise ProvenanceTruncationError( f"hash mismatch at link {link.issuer}: chain tampered or reordered" ) expected_parent = link.parent_hash root = cred.chain[0].issuer if root not in trusted_roots: raise ProvenanceTruncationError( f"reconstructed root {root} is not in the verifier's trust set" ) if require_provenance and not cred.provenance_complete: raise ProvenanceTruncationError("policy requires provenance_complete; got False") return root def authorize(cred: Credential, requested_scope: str, trusted_roots: set, current_epoch: dict, require_provenance: bool = True) -> None: grantor = verify_chain(cred, trusted_roots, require_provenance) # Enforce the *original grantor's* revocation epoch, not the broker's. if current_epoch.get(grantor, 0) > cred.leaf.revocation_epoch: raise ProvenanceTruncationError( f"grant from {grantor} revoked at epoch {current_epoch[grantor]}; " f"credential carries epoch {cred.leaf.revocation_epoch}" ) if requested_scope not in cred.leaf.scope: raise ProvenanceTruncationError( f"scope {requested_scope} not in brokered grant {sorted(cred.leaf.scope)}" ) ```