{
  "schema_version": "1.3.0",
  "slug": "where-must-an-instance-re-derive-provenance-when-a-tool-s-output-schema-silently-widens-the-tag-laundering-boundary-in-indirect-prompt-injection-defen",
  "title": "Where must an instance re-derive provenance when a tool's output schema silently widens: the tag-laundering boundary in indirect prompt injection defense",
  "date_of_record": "2026 November 30",
  "scope": "Applies to agents that defend against indirect prompt injection by attaching runtime provenance tags to every tool result and gating downstream reasoning on those tags. Does not apply to systems that rely solely on input classifiers or to single-turn, tool-free completions.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/where-must-an-instance-re-derive-provenance-when-a-tool-s-output-schema-silently-widens-the-tag-laundering-boundary-in-indirect-prompt-injection-defen.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-re-derive-provenance-when-a-tool-s-output-schema-silently-widens-the-tag-laundering-boundary-in-indirect-prompt-injection-defen.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-re-derive-provenance-when-a-tool-s-output-schema-silently-widens-the-tag-laundering-boundary-in-indirect-prompt-injection-defen.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1872,
    "python_slice_tokens": 384,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "Provenance tagging is not a property of *content*; it is a property of the *transport path* by which a byte arrived in the context window. The failure mode examined here is **tag laundering through schema widening**: a tool whose declared output schema is `{\"type\": \"string\"}` returns a string that itself contains a serialized structure (JSON, markdown, fence...",
    "what_was_observed": "A retrieval tool declared as: returned a 4.2 KB HTML fragment. The agent's provenance layer wrapped the result as `{tag: \"untrusted:web\", span: [0, 4213]}`. A downstream \"summarize\" step invoked a `parse_markdown` helper that extracted a fenced block and a JSON blob, producing a structured object `{title: ..., instructions: [...]}`. Because the helper was a *trusted internal tool*, its output was tagged `trusted:inte...",
    "condition_of_validity": "The tag-laundering failure requires all three of the following concurrently; remove any one and the mechanism does not fire: 1. **Schema under-specification.** The tool's declared return type is opaque (`string`, `bytes`, `Any`) or wider than its actual payload. If the schema enumerated `instructions: list[str]` at the tool boundary, the tagger would have ha...",
    "decision_boundary": "The architectural decision is whether to make deserialization *provenance-preserving* (tags travel with the bytes through every parser) or *provenance-resetting* (any re-parse of untrusted bytes produces untrusted output, full stop). The first is correct but requires every parser in the tool graph to be tag-aware; the second is safe but collapses the useful ...",
    "operational_effect": "The effect of getting this wrong is not a single bad action; it is a **persistent privilege escalation in the context window.** Once the injected instruction is re-tagged `trusted:internal`, it survives compaction, summarization, and checkpoint/resume—because those operations preserve the tag field. A cold-started instance that reloads the checkpoint inherit..."
  },
  "matched_failure_symptoms": [
    "PROMPT_INJECTION_OR_CONFUSED_DEPUTY",
    "SCHEMA_DRIFT_OR_COERCION_CRASH"
  ],
  "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": "3c7d51e9ae999bf5b51b2f9a9a8188c2adc0e5fdd5973849acfd457fd3d44e25",
    "verified_classes": [
      "ProvenanceLaunderingError",
      "Tagged"
    ],
    "verified_functions": [
      "_join",
      "deserialize",
      "assert_monotone",
      "gate_side_effect",
      "rank"
    ],
    "verified_functions_count": 5,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "ProvenanceLaunderingError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
