{
  "schema_version": "1.3.0",
  "slug": "which-invariants-prevent-privilege-amplification-across-attenuated-macaroon-chains-when-caveat-predicates-are-evaluated-out-of-order",
  "title": "Which invariants prevent privilege amplification across attenuated macaroon chains when caveat predicates are evaluated out of order",
  "date_of_record": "2026 November 15",
  "scope": "Applies to agent-to-agent delegation systems where authority is transferred as a chain of macaroon-style tokens (root secret → attenuated roots → bearer), and where each hop appends caveats whose predicates are evaluated by the resource server at presentation time. Does not apply to bearer tokens with server-side session state, nor to single-hop capability tokens where no attenuation chain exists.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/which-invariants-prevent-privilege-amplification-across-attenuated-macaroon-chains-when-caveat-predicates-are-evaluated-out-of-order.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/which-invariants-prevent-privilege-amplification-across-attenuated-macaroon-chains-when-caveat-predicates-are-evaluated-out-of-order.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/which-invariants-prevent-privilege-amplification-across-attenuated-macaroon-chains-when-caveat-predicates-are-evaluated-out-of-order.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2083,
    "python_slice_tokens": 645,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "Attenuation is a *syntactic* operation: appending a caveat to a macaroon can only shrink the set of presentations that satisfy it, because satisfaction requires the conjunction of all caveats. This monotonicity is the entire security argument for delegation chains. It holds only if the verifier evaluates the **full conjunction of the presented chain** and on...",
    "what_was_observed": "A three-agent pipeline: orchestrator `O` holds a root macaroon `R` scoped to `service:storage` with caveat `account=acme`. `O` delegates to planner `P` by attenuating `R` with `action in {read, list}`. `P` delegates to worker `W` by attenuating with `path prefix=/reports`. The intended authority of `W` is `{read, list} ∧ {/reports} ∧ {acme}`. `W` was observed successfully performing `write` on `/reports/q3.csv` under...",
    "condition_of_validity": "The monotonicity guarantee is valid only under all of the following, jointly: 1. **Secret custody.** A delegating agent must not possess the root secret or any secret that permits minting a token not descended from its own token. If it does, attenuation is advisory, not enforced. 2. **Chain commitment.** Each attenuation must commit to its predecessor — the ...",
    "decision_boundary": "The boundary is between **attenuation** (append to a token you hold) and **derivation** (mint from a secret you hold). These are operationally distinct and must not share a code path. - If an agent holds only its own token and no minting secret → it can only attenuate; monotonicity holds by construction. - If an agent holds a minting secret → it can derive s...",
    "operational_effect": "After the incident, delegation was restructured so that `P` never held the root secret; `P` received `M_A` and could only call `attenuate`. Each attenuation binds the parent signature into the child's signature input, and the verifier reconstructs and checks the full chain, rejecting any token whose declared parent signature does not match a presented ancest..."
  },
  "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": "b2d330f4e1d9e9d1f98c24bbddefeced0c91982004334589b7f9a3f755b5c10a",
    "verified_classes": [
      "ChainIntegrityError",
      "Caveat",
      "Macaroon"
    ],
    "verified_functions": [
      "_sign",
      "attenuate",
      "verify_chain",
      "authorize",
      "_evaluate"
    ],
    "verified_functions_count": 5,
    "defensive_guards_count": 7,
    "raised_exceptions": [
      "ChainIntegrityError"
    ],
    "sample_fail_closed_invariants": [
      "empty chain",
      "root signature invalid",
      "child does not descend from presented parent (sibling derivation or omitted ancestor)",
      "caveat set is not a prefix-preserving superset of parent"
    ],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib",
      "hmac",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
