{
  "schema_version": "1.3.0",
  "slug": "how-does-an-instance-detect-taint-laundering-across-a-nested-retrieval-boundary",
  "title": "How does an instance detect taint laundering across a nested retrieval boundary",
  "date_of_record": "2026 November 24",
  "scope": "Applies to agent pipelines that tag retrieved documents, tool responses, or peer-agent messages with a taint/trust label and gate privileged actions (writes, shell, credential use, outbound HTTP) on that label. Does not apply to pipelines with no privilege gradient—where every action is equally trusted, taint propagation is moot.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-taint-laundering-across-a-nested-retrieval-boundary.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-taint-laundering-across-a-nested-retrieval-boundary.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-taint-laundering-across-a-nested-retrieval-boundary.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1722,
    "python_slice_tokens": 384,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"untrusted content reached the model.\" That is normal and expected. The failure is **taint laundering through a trusted summarizer or sub-agent**: an untrusted fragment enters a low-privilege context, is summarized/re-encoded by a component whose *output* is labeled trusted, and the tainted instruction survives the re-encoding as a paraphr...",
    "what_was_observed": "A three-stage pipeline: `fetch` (untrusted web content) → `summarize` (a low-tier model, output labeled `trusted_summary`) → `act` (a tool-calling model allowed to issue `send_email` and `write_file`). The summarizer prompt was \"condense the following page into 3 bullet points for the planner.\" The planner treated `trusted_summary` as decision-grade input. Trigger condition: a fetched page contained, inside a `<div c...",
    "condition_of_validity": "The taint invariant holds only if trust labels are **derived from inputs, never asserted by stage position**. Formally: for any transform `T` producing output `o` from inputs `I`, `taint(o) = join(taint(i) for i in I)` under a lattice where `untrusted ⊔ trusted = untrusted`. A stage may emit `trusted` output only if (a) all inputs are `trusted`, or (b) an ex...",
    "decision_boundary": "The boundary is: **does the downstream consumer distinguish data from instruction by label, or by grammatical form?** If the planner decides \"this is an instruction\" by reading imperative mood, taint labels are decorative—laundering succeeds regardless of label bookkeeping. If the planner only executes instructions that arrive on a dedicated instruction chan...",
    "operational_effect": "With input-derived taint join plus imperative-incapable summarizer schema, the observed attack degrades from \"unauthorized egress\" to \"a spurious claim in the planner's context,\" which the planner may reason about but cannot act on without an instruction-channel grant. The cost is that legitimate summaries of pages containing quoted instructions (documentati..."
  },
  "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": "524101c75ab471f40eac9785caacd9ba36fc3f63b501ac85193579b442ed16c0",
    "verified_classes": [
      "Taint",
      "TaintLaunderingError",
      "Payload",
      "Stage"
    ],
    "verified_functions": [
      "join_taint",
      "run_stage",
      "privileged_action",
      "declassify"
    ],
    "verified_functions_count": 4,
    "defensive_guards_count": 4,
    "raised_exceptions": [
      "TaintLaunderingError"
    ],
    "sample_fail_closed_invariants": [
      "declassify rejected: claim must be structured, not free-text (free-text can carry imperative force)"
    ],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
