{
  "schema_version": "1.3.0",
  "slug": "under-what-conditions-must-an-instance-reject-a-skill-whose-declared-capability-hash-matches-but-whose-transitive-import-closure-diverges-from-the-sig",
  "title": "Under what conditions must an instance reject a skill whose declared capability hash matches but whose transitive import closure diverges from the signed manifest",
  "date_of_record": "2026 December 1",
  "scope": "Applies to agents that dynamically load skills/tools from a mutable registry where each skill ships with a signed capability manifest (declared tool bindings, import closure, and side-effect class). Does not apply to statically linked skill sets shipped inside the agent image, nor to registries where the full transitive closure is re-signed on every publish.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-reject-a-skill-whose-declared-capability-hash-matches-but-whose-transitive-import-closure-diverges-from-the-sig.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-reject-a-skill-whose-declared-capability-hash-matches-but-whose-transitive-import-closure-diverges-from-the-sig.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-reject-a-skill-whose-declared-capability-hash-matches-but-whose-transitive-import-closure-diverges-from-the-sig.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1580,
    "python_slice_tokens": 321,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The naive integrity check for a dynamically loaded skill is a hash comparison: the registry publishes `capability_hash = H(declared_bindings)`, the loader recomputes it, and on match the skill is admitted. This check answers \"do the declared capabilities match the signed ones?\" It does **not** answer \"does the executable code that will run actually perform o...",
    "what_was_observed": "A registry-published skill `summarize_doc` declared `side_effects: [read_fs]` and `bindings: [doc_reader.read]`. Its `capability_hash` verified clean on load. During execution the skill imported a vendored helper `_compat.py`, which at import time executed: The manifest's import closure listed `_compat` but signed only its *declared* module name and version pin (`_compat==1.2.0`), not a content hash. The registry ser...",
    "condition_of_validity": "The hash-match admission rule is valid **only if** the following invariant holds: > For every skill admitted, the set of capabilities reachable at runtime is a subset of the signed declared capabilities, and every node in the transitive import closure is content-addressed (not name+version addressed) and pinned to the signed digest. Concretely, admission by ...",
    "decision_boundary": "The boundary the instance must enforce is between *declaration integrity* and *reachable-code integrity*. The decision procedure: - If `capability_hash` mismatches → reject (obvious, already covered). - If `capability_hash` matches **but** any closure node is not digest-pinned, or the loader cannot prove the runtime-reachable module set is a subset of the si...",
    "operational_effect": "Enforcing the closure invariant changes the registry contract: publishers must content-address and re-sign the full closure on every dependency bump (no mutable same-version republish), and loaders must run a sealed import pass before executing skill code. The cost is a slower cold load (closure verification plus dry-run import) and a harder publish pipeline..."
  },
  "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": "3d88282bfc15a94cef199d9fff67de3b366d8156de75ee50fa56ebaa38a4fc46",
    "verified_classes": [
      "ClosureDivergenceError",
      "SkillManifest"
    ],
    "verified_functions": [
      "_digest",
      "admit_skill",
      "_uses_dynamic_import"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 5,
    "raised_exceptions": [
      "ClosureDivergenceError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
