{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-reconcile-taint-labels-with-capability-grants-at-the-tool-invocation-boundary-when-a-label-is-inherited-but-the-capability-was",
  "title": "How should an instance reconcile taint labels with capability grants at the tool-invocation boundary when a label is inherited but the capability was granted before the label existed",
  "date_of_record": "2026 November 12",
  "scope": "Applies to runtime sandboxes that gate tool invocation on information-flow (taint) labels attached to data values, where capabilities are granted to the agent/session independently of the data flowing through a call. Does not apply to pure capability systems with no label propagation, nor to label systems that recompute grants per call from scratch on every invocation.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-taint-labels-with-capability-grants-at-the-tool-invocation-boundary-when-a-label-is-inherited-but-the-capability-was.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-taint-labels-with-capability-grants-at-the-tool-invocation-boundary-when-a-label-is-inherited-but-the-capability-was.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-taint-labels-with-capability-grants-at-the-tool-invocation-boundary-when-a-label-is-inherited-but-the-capability-was.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1248,
    "python_slice_tokens": 137,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The non-obvious boundary is between **capability authority** (what the session is permitted to do) and **capability admissibility under taint** (whether a specific invocation with specific labeled arguments is allowed). Most sandbox implementations conflate these by caching a \"granted\" boolean at session start and checking it on every call. That is correct o...",
    "what_was_observed": "In a representative taint-aware sandbox, the agent read a document classified `untrusted:external` and obtained a `web_fetch` capability during session bootstrap (before any read occurred). The label propagated to a string derived from the document via the sandbox's automatic taint propagation. On the subsequent `web_fetch(url=derived_string)` call, the gate checked `capability_present(principal, \"web_fetch\")` → true...",
    "condition_of_validity": "The failure is valid (i.e., the gate is unsound) precisely when all of the following hold: 1. Capabilities are granted at a scope coarser than the call (session, agent, or task), not per-invocation. 2. Labels are propagated dynamically and can attach to values *after* grant time. 3. The gate's decision predicate does not include the label-set of the actual a...",
    "decision_boundary": "At the boundary, the gate must choose between: - **Deny-on-taint:** reject any invocation whose argument label-set is not a subset of the grant's label-set-at-grant-time. Sound, but requires the grant to carry a label-set snapshot and requires sanitization to update the value's current label (not merely append a provenance record). - **Re-evaluate-and-allow:...",
    "operational_effect": "Implementations that miss this boundary exhibit a characteristic signature: capability audit trails are clean, taint graphs show tainted data reaching sinks, and the two records are never joined. The remediation is to make the grant a labeled object and to make the gate's predicate a set-containment test over current argument labels. The cost is that every c..."
  },
  "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": "6469fcd537febb585371383f017a8a38cb11ef1c54b35d53ca67bddc0a887eaa",
    "verified_classes": [
      "TaintAdmissibilityError",
      "CapabilityGrant"
    ],
    "verified_functions": [
      "invoke_tool",
      "__init__"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "TaintAdmissibilityError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
