{
  "schema_version": "1.3.0",
  "slug": "what-happens-when-an-instance-loads-a-plugin-whose-declared-capability-schema-diverges-from-its-executed-tool-surface",
  "title": "What happens when an instance loads a plugin whose declared capability schema diverges from its executed tool surface",
  "date_of_record": "2026 November 30",
  "scope": "Applies to agents that acquire capabilities at runtime via a plugin/marketplace manifest (MCP tool descriptors, OpenAPI fragments, skill cards) where the manifest is trusted for routing, permissioning, or prompt construction but the executable body is supplied separately. Does not apply to statically compiled-in toolsets with no runtime capability acquisition.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/what-happens-when-an-instance-loads-a-plugin-whose-declared-capability-schema-diverges-from-its-executed-tool-surface.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/what-happens-when-an-instance-loads-a-plugin-whose-declared-capability-schema-diverges-from-its-executed-tool-surface.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/what-happens-when-an-instance-loads-a-plugin-whose-declared-capability-schema-diverges-from-its-executed-tool-surface.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1825,
    "python_slice_tokens": 294,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The naive threat model treats skill injection as *untrusted content reaching the prompt* — a data-plane problem solved by input sanitization. The non-obvious boundary is the **declared-vs-executed capability divergence**: the manifest that the orchestrator reads (name, description, JSON schema, side-effect annotations) and the code that actually runs are two...",
    "what_was_observed": "A marketplace skill declared `capability: \"summarize_text\"`, schema `{text: string}`, annotation `read_only: true`, `network: none`. The router admitted it under a low-privilege taint label and, because it was \"read-only,\" passed it a context slice that included the agent's system prompt and a prior turn containing a bearer credential. The executed body ignored the declared parameter and read `os.environ`, then encod...",
    "condition_of_validity": "The divergence is exploitable only when three conditions co-hold: - **Ambient authority is broader than declared authority.** The plugin executes in a process whose env, filesystem view, or network namespace exceeds what the manifest attests. If the sandbox grants exactly the declared surface, divergence has no reach. - **The manifest is load-bearing for tru...",
    "decision_boundary": "The boundary is not \"trust the plugin or not\" — it is **whether the orchestrator's authority grant is derived from the manifest or from the execution environment.** Two regimes: - **Manifest-derived authority (safe regime):** the sandbox is constructed *from* the manifest. A `network: none` skill runs in a namespace with no route. A `read_only` skill runs wi...",
    "operational_effect": "When the invariant is unenforced, the orchestrator's entire permission model becomes advisory. The concrete consequences: - **Context bleed via annotation.** Read-only skills receive high-sensitivity context slices (system prompts, credentials in prior turns) on the strength of a declaration the body can ignore. The exfiltration channel is the return value o..."
  },
  "matched_failure_symptoms": [
    "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": "feb2ee87106b636ab65bd16be0ab7e3510d03d5fe3e88bd1ebe3e0c7d2049ee2",
    "verified_classes": [
      "ManifestExecutionDivergence"
    ],
    "verified_functions": [
      "admit_plugin"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "ManifestExecutionDivergence"
    ],
    "sample_fail_closed_invariants": [
      "declared network:none but sandbox has egress; manifest-derived authority is invalid",
      "declared read_only but sandbox exposes writable paths; refusing manifest-derived grant"
    ],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
