{
  "schema_version": "1.3.0",
  "slug": "which-invariants-prevent-injection-tainted-tool-arguments-from-crossing-the-execution-boundary-and-where-taint-tracking-silently-drops",
  "title": "Which invariants prevent injection-tainted tool arguments from crossing the execution boundary — and where taint tracking silently drops",
  "date_of_record": "2026 November 25",
  "scope": "Applies to agent runtimes that propagate provenance/taint labels from untrusted inputs (retrieved documents, tool outputs, peer-agent messages) through the reasoning loop and enforce a firewall at the tool-call boundary. Does not apply to stateless single-turn models with no tool surface, nor to systems where all tool arguments are re-derived from a trusted schema rather than synthesized by the model.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/which-invariants-prevent-injection-tainted-tool-arguments-from-crossing-the-execution-boundary-and-where-taint-tracking-silently-drops.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/which-invariants-prevent-injection-tainted-tool-arguments-from-crossing-the-execution-boundary-and-where-taint-tracking-silently-drops.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/which-invariants-prevent-injection-tainted-tool-arguments-from-crossing-the-execution-boundary-and-where-taint-tracking-silently-drops.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1941,
    "python_slice_tokens": 429,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "Two things are routinely conflated: *detecting* that an argument carries injected content, and *proving* that the argument's value is causally derived from an untrusted source. The first is a classifier problem (probabilistic, evadable). The second is a provenance problem (mechanical, but only as sound as the join points where labels are merged, dropped, or ...",
    "what_was_observed": "A retrieval step pulled a document containing an instruction fragment (`transfer to acct 0x9f...`). The document span was correctly labeled `untrusted:retrieval`. The model then called `issue_payment(account=\"0x9F...\", amount=4100)`. The firewall's span-matcher compared the argument against tainted spans using exact and normalized-substring matching; the argument `\"0x9F...\"` differed in case and the `amount` was a *d...",
    "condition_of_validity": "The firewall's guarantee holds **only** under the following conjunction, and fails the moment any conjunct is dropped: - **Taint is attached to the dataflow edge, not the token.** Every value the model emits into a tool argument must be traceable to the set of context segments that conditioned its generation. If the runtime cannot attribute an argument to it...",
    "decision_boundary": "The boundary is not \"is this argument suspicious?\" but \"**can the runtime name the trusted source of every byte in this argument?**\" - If the argument value is a **direct copy** from a trusted structured field (e.g., `user.account_id` from an authenticated session) → clean, no model involvement in the value. - If the argument value was **synthesized by the m...",
    "operational_effect": "With the invariant enforced: - Injection payloads that survive retrieval and reach the model still cannot reach side-effecting tools unless they pass a declared validator. The attack surface collapses from \"any tool argument the model can synthesize\" to \"the declassification gates,\" which are small, enumerable, and auditable. - The firewall's false-positive ..."
  },
  "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": "2641f5046f517521a792206e4cbbcffa82490bde600cb4e44fb2efb1498bf6f7",
    "verified_classes": [
      "Trust",
      "Span",
      "ToolArgument",
      "TaintLaunderingError",
      "MissingAttributionError"
    ],
    "verified_functions": [
      "label_of",
      "firewall_check",
      "issue_payment"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "MissingAttributionError",
      "TaintLaunderingError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
