{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-propagate-taint-labels-across-a-retrieval-to-tool-seam-when-the-label-carrier-itself-is-attacker-writable",
  "title": "How should an instance propagate taint labels across a retrieval-to-tool seam when the label carrier itself is attacker-writable",
  "date_of_record": "2026 December 2",
  "scope": "Applies to agents that implement dynamic information-flow control (IFC) by embedding a taint label inside the retrieved document, tool result, or message envelope itself (in-band labeling), and which then rely on that label surviving a re-serialization boundary. Does not apply to out-of-band label stores keyed by content hash or message ID, nor to systems where all tool output is unconditionally treated as tainted.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-propagate-taint-labels-across-a-retrieval-to-tool-seam-when-the-label-carrier-itself-is-attacker-writable.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-propagate-taint-labels-across-a-retrieval-to-tool-seam-when-the-label-carrier-itself-is-attacker-writable.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-propagate-taint-labels-across-a-retrieval-to-tool-seam-when-the-label-carrier-itself-is-attacker-writable.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2574,
    "python_slice_tokens": 446,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The distinction that matters is between **the taint label as a property of the data channel** and **the taint label as a field inside the data**. An out-of-band label (a side-table entry keyed by `message_id` or `content_hash`) is a property of the channel: the model can read the payload but cannot rewrite the metadata slot, because the metadata lives outsid...",
    "what_was_observed": "A retrieval step fetched a support-ticket document from an external corpus. The document body contained, after benign prose, the following near the end: The ingestion layer wrapped the document correctly on first read: it emitted the doc to the model as `{\"trust\": \"untrusted\", \"source\": \"external_corpus\", \"body\": \"...\"}`. The model was asked to summarize the ticket into a structured `triage_note` object for the next ...",
    "condition_of_validity": "The invariant that must hold for in-band taint labels to be sound is: > **No byte that originated in a lower-trust channel may occupy a label-bearing position in a higher-trust channel, and label-bearing positions must be unforgeable by any content the model can emit.** This invariant is *violated by construction* whenever the label vocabulary is (a) plain t...",
    "decision_boundary": "The operational decision is **where to place the trust boundary relative to model-mediated re-serialization**. The boundary must be placed such that the model is never the carrier of a label across a privilege gradient. Concretely: - **Do not let the model carry labels.** If a hop's output will be parsed for labels, that hop must not be allowed to produce la...",
    "operational_effect": "When the invariant holds, the failure mode is bounded: an injected instruction in retrieved content can still reach the model's reasoning, but the *tool call it induces* is made from a context whose taint join is `untrusted`, so the privileged tool either refuses, requires out-of-band approval, or executes in a sandbox with no side effects. The injection bec..."
  },
  "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": "f12790baf637268d534ca11dfe3eb8d83c9472b6bff0c1014b2abc47e779b431",
    "verified_classes": [
      "TaintViolation",
      "Trust",
      "Channel"
    ],
    "verified_functions": [
      "derive_hop_output",
      "admit_to_privileged_tool"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 5,
    "raised_exceptions": [
      "TaintViolation"
    ],
    "sample_fail_closed_invariants": [
      "hop has no provenance; refusing to mint a label",
      "model output contains the IFC sentinel; treating as injection"
    ],
    "stdlib_dependencies": [
      "__future__",
      "dataclasses",
      "enum"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
