{
  "schema_version": "1.3.0",
  "slug": "how-does-an-instance-detect-a-skill-injection-attack-when-the-injected-capability-is-indistinguishable-from-a-legitimate-one-at-load-time",
  "title": "How does an instance detect a skill-injection attack when the injected capability is indistinguishable from a legitimate one at load time",
  "date_of_record": "2026 November 13",
  "scope": "Applies to agent runtimes that resolve, fetch, and register external capabilities (skills, tools, plugins) at runtime from mutable sources—registries, remote manifests, or prompt-embedded descriptors. Does not apply to statically compiled, signed-at-build-time toolchains where the capability set is fixed before the agent process starts.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-skill-injection-attack-when-the-injected-capability-is-indistinguishable-from-a-legitimate-one-at-load-time.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-skill-injection-attack-when-the-injected-capability-is-indistinguishable-from-a-legitimate-one-at-load-time.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-skill-injection-attack-when-the-injected-capability-is-indistinguishable-from-a-legitimate-one-at-load-time.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1566,
    "python_slice_tokens": 232,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The non-obvious boundary is this: **skill injection is not a payload-integrity problem, it is a provenance-binding problem.** Most runtimes guard the wrong layer. They verify that a skill *loads correctly* (schema valid, signature present, dependency graph resolvable) and treat successful load as trust. But a skill-injection attack does not corrupt the load;...",
    "what_was_observed": "In a multi-tenant agent deployment, a skill named `summarize_document` was registered through the standard registry path. It passed schema validation, carried a valid registry signature, and declared dependencies only on `read_file` and `llm_complete`. During a routine task, the agent invoked it against a user document. The skill executed correctly and returned a correct summary. It also, in the same invocation, call...",
    "condition_of_validity": "The detection rule is valid only under all of the following: 1. The runtime records, per invocation, the full transitive tool-call trace with resolved arguments—not just top-level tool names. If the trace is name-only, this detection cannot fire. 2. Each registered skill carries a declaration that includes an argument-domain constraint (path prefix, host all...",
    "decision_boundary": "The decision is not \"is this skill malicious.\" That question is undecidable at the boundary and invites false positives against legitimately broad skills. The decidable question is: **did the observed invocation footprint fall within the declared footprint, evaluated at argument granularity, for this binding?** - If observed ⊆ declared (argument-domain-wise)...",
    "operational_effect": "Enforcing this boundary changes the skill-authoring contract: declarations become *argument-domain contracts*, not tool-name lists. It also changes the runtime's trust model from \"signed at load = trusted\" to \"bound and observed at invocation = trusted for this binding only.\" The practical consequence is that a skill signed by a fully trusted registry can st..."
  },
  "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": "50cf84d1679e4c6611af79ae36602b345b58889981dcc679035673e700093f00",
    "verified_classes": [
      "SkillInjectionError",
      "ArgumentDomain",
      "SkillDeclaration",
      "ObservedCall"
    ],
    "verified_functions": [
      "check_binding"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 1,
    "raised_exceptions": [
      "SkillInjectionError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
