{
  "schema_version": "1.3.0",
  "slug": "why-does-an-instance-lose-capability-scope-enforcement-when-a-tool-result-is-replayed-through-a-cached-warrant-rather-than-re-minted-per-invocation",
  "title": "Why does an instance lose capability-scope enforcement when a tool result is replayed through a cached warrant rather than re-minted per invocation",
  "date_of_record": "2026 November 30",
  "scope": "Applies to agent runtimes that enforce tool-invocation policy via capability tokens (warrants) bound to a scope and TTL, where tool results are cached and replayed to the reasoning loop. Does not apply to runtimes that re-mint a fresh warrant on every dispatch, nor to pure in-process tools with no egress surface.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/why-does-an-instance-lose-capability-scope-enforcement-when-a-tool-result-is-replayed-through-a-cached-warrant-rather-than-re-minted-per-invocation.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/why-does-an-instance-lose-capability-scope-enforcement-when-a-tool-result-is-replayed-through-a-cached-warrant-rather-than-re-minted-per-invocation.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/why-does-an-instance-lose-capability-scope-enforcement-when-a-tool-result-is-replayed-through-a-cached-warrant-rather-than-re-minted-per-invocation.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1922,
    "python_slice_tokens": 449,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "There are two structurally different things a runtime can cache, and conflating them is the entire failure: 1. **Result caching** — memoizing the *output* of a tool call keyed by `(tool_id, canonical_args, scope_hash)`. This is sound: the output is a pure function of those inputs *at the time it was produced*. 2. **Warrant caching** — reusing the *capability...",
    "what_was_observed": "A research agent was granted a capability-scoped warrant for `http.fetch` with scope `{allowed_hosts: [\"arxiv.org\"], egress_bytes_max: 2_000_000, ttl: 300s}`. During a literature sweep it fetched ~40 arxiv URLs; the runtime's result cache (keyed on `(tool_id, args, scope_hash)`) populated normally and the policy decision point (PDP) short-circuited on cache hits, replaying the original warrant alongside the cached bo...",
    "condition_of_validity": "The invariant that must hold is: > **No tool executes, and no cached result is delivered to the reasoning loop, unless a warrant minted against the *current* policy snapshot authorizes it. A cache hit may skip execution but must never skip authorization.** Concretely, for any dispatch the runtime must satisfy, in order: 1. `w = mint(subject, tool_id, args, p...",
    "decision_boundary": "The boundary between \"safe to cache\" and \"must re-authorize\" is drawn by **whether the policy inputs can change independently of the cache key**: - If the only inputs to authorization are `(subject, tool_id, args)` and none of these can be mutated by an out-of-band operator action, the warrant is a pure function of the key and caching it is sound. - If *any*...",
    "operational_effect": "After the incident, the runtime was changed so that: - The result cache key dropped `scope_hash` and gained `policy_version`; a policy mutation bumps `policy_version`, which naturally invalidates all result entries minted under the old version. - The dispatch path unconditionally calls `mint()` before consulting the cache; the PDP has a hard latency budget (..."
  },
  "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": "7d6a8d01de9aa94c1eca307211ece50bc8bda6243bc6b8d60513074e4a3e7062",
    "verified_classes": [
      "StaleWarrantError",
      "PolicySnapshot",
      "Warrant",
      "Runtime"
    ],
    "verified_functions": [
      "_cache_key",
      "mint",
      "_authorize",
      "dispatch",
      "_execute"
    ],
    "verified_functions_count": 5,
    "defensive_guards_count": 4,
    "raised_exceptions": [
      "StaleWarrantError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
