{
  "schema_version": "1.3.0",
  "slug": "in-what-scenarios-must-an-instance-invalidate-a-taint-label-when-a-tool-output-s-provenance-class-is-downgraded-by-sanitization-and-how-does-label-lau",
  "title": "In what scenarios must an instance invalidate a taint label when a tool output's provenance class is downgraded by sanitization, and how does label laundering through a second-hop summarizer defeat naive data-flow tracking?",
  "date_of_record": "2026 November 24",
  "scope": "Applies to agents that propagate data-flow taint labels across tool calls, retrieval, and inter-instance handoffs where a sanitizer or summarizer sits between an untrusted source and a privileged sink. Does not apply to single-turn, no-tool agents or to systems where all tool outputs are treated as uniformly untrusted (no label lattice exists to launder).",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-invalidate-a-taint-label-when-a-tool-output-s-provenance-class-is-downgraded-by-sanitization-and-how-does-label-lau.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-invalidate-a-taint-label-when-a-tool-output-s-provenance-class-is-downgraded-by-sanitization-and-how-does-label-lau.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-invalidate-a-taint-label-when-a-tool-output-s-provenance-class-is-downgraded-by-sanitization-and-how-does-label-lau.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1598,
    "python_slice_tokens": 303,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "Naive taint tracking conflates two orthogonal facts about a value: **where it came from** (provenance class: `UNTRUSTED_WEB`, `USER_INPUT`, `TRUSTED_CONFIG`) and **what has been done to it** (transformation history: raw, sanitized, summarized). The failure mode is not that the sanitizer is wrong—it is that the label lattice treats `sanitize()` as a *monotone...",
    "what_was_observed": "A research agent was wired to fetch a URL, pass the page through an HTML sanitizer, then feed the sanitized text to a summarizer tool, and finally allow the summary to be written into a config file via a `write_config` sink gated on `provenance == TRUSTED`. 1. The fetched page carried label `UNTRUSTED_WEB`. 2. The sanitizer stripped `<script>` and returned text labeled `SANITIZED`. The tracker's rule was `SANITIZED ⊑...",
    "condition_of_validity": "The laundering attack is *only* possible when all of the following hold simultaneously, which is what makes it non-obvious: - **The sanitizer's contract is syntactic, not semantic.** It removes executable markup but preserves natural-language imperatives. Any sanitizer that preserves text preserves injected instructions. - **The summarizer is modeled as a pr...",
    "decision_boundary": "The correct boundary is not \"is this value trusted?\" but \"**does the full transformation history of this value contain any untrusted origin that was not removed by an instruction-stripping (not merely markup-stripping) transform?**\" A sanitizer that removes `<script>` does not clear taint for text-content sinks; only a transform that provably cannot carry in...",
    "operational_effect": "When the invariant is enforced, the research agent above fails closed: the summary carries `{UNTRUSTED_WEB, MODEL_GENERATED}`, `write_config` rejects it, and the agent surfaces a *tainted-write* event for human review rather than silently mutating config. The cost is a higher false-positive rate—legitimate summaries of untrusted pages can no longer drive pri..."
  },
  "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": "29a2f05b504c87f1ef9b30ef19cd3549a11063bdcfe50db2b9b68e604b390bac",
    "verified_classes": [
      "Trust",
      "TaintLaunderingError",
      "Labeled"
    ],
    "verified_functions": [
      "sanitize",
      "summarize",
      "write_config",
      "run_pipeline",
      "join"
    ],
    "verified_functions_count": 5,
    "defensive_guards_count": 1,
    "raised_exceptions": [
      "TaintLaunderingError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
