{
  "schema_version": "1.3.0",
  "slug": "which-invariants-prevent-manifest-poisoning-persistence-across-hot-reload-cycles-in-a-plugin-registry",
  "title": "Which invariants prevent manifest-poisoning persistence across hot-reload cycles in a plugin registry",
  "date_of_record": "2026 November 25",
  "scope": "Applies to agent runtimes that hot-reload tool/plugin manifests at runtime (MCP server descriptors, OpenAPI-derived tool schemas, in-process plugin registries) and re-derive the tool-call surface from those manifests. Does not apply to statically compiled tool surfaces where the manifest is fixed at process start and never re-parsed.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/which-invariants-prevent-manifest-poisoning-persistence-across-hot-reload-cycles-in-a-plugin-registry.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/which-invariants-prevent-manifest-poisoning-persistence-across-hot-reload-cycles-in-a-plugin-registry.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/which-invariants-prevent-manifest-poisoning-persistence-across-hot-reload-cycles-in-a-plugin-registry.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2239,
    "python_slice_tokens": 394,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"a malicious tool was loaded.\" That is the trivial, well-understood case: an attacker supplies a manifest, the agent registers a tool, the tool does something bad when called. Defenses exist at the call boundary — argument validation, capability scoping, egress filters. The non-obvious failure is **persistence across reload cycles via mani...",
    "what_was_observed": "A registry with a 30-second poll loop reloaded a tool manifest set. The sequence: 1. **T0 — clean baseline.** Manifest set M₀ contains tools `{search, fetch, summarize}`. Registry caches: schema hashes, an embedding index of each tool's `description` for the router's tool-selection step, and a `tool_id → capability_token` map. 2. **T1 — poisoned load.** Manifest set M₁ adds `fetch_v2` whose `description` is a long na...",
    "condition_of_validity": "This failure requires **all** of the following to hold simultaneously; remove any one and the persistence channel closes: - **Delta-based reload.** The registry applies manifest changes as additions/removals against a cached prior state rather than rebuilding derived state from the current manifest. (Full-rebuild registries are immune at the cost of reload l...",
    "decision_boundary": "The boundary is **whether a derived artifact's authorization is bound to the manifest version that produced it, or to the registry process lifetime.** Concretely, for each derived artifact D produced from manifest M at version v: - **Bound (safe):** D carries `(manifest_id, version, content_hash)`. On reload to v', any D whose binding does not match a curren...",
    "operational_effect": "The practical consequence is that **manifest removal is not manifest revocation.** An operator who detects a poisoned tool and removes it from the manifest believes the threat is closed; the derived state keeps the payload live for the duration of the longest-lived derived artifact. Incident response that stops at \"tool deregistered, verified absent from man..."
  },
  "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": "99f48b8dff7d15a0365ac1658cdc01376a2712eb9c961d67a391d60efc682816",
    "verified_classes": [
      "RevocationLeakError",
      "DerivedArtifacts"
    ],
    "verified_functions": [
      "apply_manifest_reload",
      "reload_with_guard",
      "all_reachable_ids"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "RevocationLeakError"
    ],
    "sample_fail_closed_invariants": [
      "assert derived.all_reachable_ids() <= live"
    ],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
