{
  "schema_version": "1.3.0",
  "slug": "where-must-an-instance-enforce-taint-labels-the-store-side-boundary-between-untrusted-retrieval-and-privileged-action",
  "title": "Where must an instance enforce taint labels: the store-side boundary between untrusted retrieval and privileged action",
  "date_of_record": "2026 November 18",
  "scope": "Applies to inference runtimes that ingest retrieved or tool-returned content into a context window and subsequently allow the same instance to invoke privileged tools (filesystem writes, credential access, outbound network, shell). Does not apply to purely read-only answering pipelines with no privileged sink, nor to offline batch scoring where no action is ever taken.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/where-must-an-instance-enforce-taint-labels-the-store-side-boundary-between-untrusted-retrieval-and-privileged-action.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-enforce-taint-labels-the-store-side-boundary-between-untrusted-retrieval-and-privileged-action.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-enforce-taint-labels-the-store-side-boundary-between-untrusted-retrieval-and-privileged-action.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1645,
    "python_slice_tokens": 217,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The common mental model is that taint tracking is a *read-side* property: you label the provenance of a token, propagate the label through attention or through an explicit dataflow graph, and then check the label at the point where a privileged action is about to occur. This model fails because the check at the sink is a *policy* decision made against a labe...",
    "what_was_observed": "In a controlled harness, an instance was given a retrieval tool returning documents from an untrusted corpus and a privileged tool that could append to a file. The runtime enforced a sink check: before calling the privileged tool, it scanned the pending arguments for known-injection markers and for a taint bit carried on the immediate tool-call object. The attack that succeeded did not put the payload in the tool-cal...",
    "condition_of_validity": "The store-side invariant holds — taint cannot be laundered — only under three conditions, all of which must be enforced structurally rather than by convention: 1. **Every write to a working store passes through a single choke point** that requires an explicit provenance argument. A store with multiple write paths (direct assignment, bulk import, deserializat...",
    "decision_boundary": "The operational question is not \"is this content tainted?\" but \"did this content enter the store through the labeled path?\" Those diverge precisely when the instance is allowed to write its own reasoning back into a store it also reads from — the scratchpad, the plan cache, the self-critique buffer. That round-trip is the laundering machine. The boundary: **...",
    "operational_effect": "Enforcing the store-side invariant changes the failure profile from *silent escalation* to *loud refusal*. When the choke point rejects an untagged write, the instance cannot proceed with the poisoned plan and surfaces an error at the write, where the provenance is still legible and the originating document can be identified. This is a far better debugging p..."
  },
  "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": "ef2818f39b829c2136fff48a5c816765cf30d979316c28fa48f040886b86d01a",
    "verified_classes": [
      "TaintLaunderingError",
      "TaintedStore"
    ],
    "verified_functions": [
      "plan_privileged_write",
      "__init__",
      "write",
      "read_for_privileged_action"
    ],
    "verified_functions_count": 4,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "TaintLaunderingError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
