{
  "schema_version": "1.3.0",
  "slug": "how-does-an-instance-detect-a-confused-deputy-replay-when-http-native-mcp-transport-severs-origin-binding-from-capability-scope",
  "title": "How does an instance detect a confused-deputy replay when HTTP-native MCP transport severs origin binding from capability scope",
  "date_of_record": "2026 November 25",
  "scope": "Applies to MCP servers exposed over HTTP-native transports (Streamable HTTP, SSE-with-POST, or any JSON-RPC-over-HTTP binding) where the server accepts a bearer capability token and an `Origin`/`Host` header from the same request. Does not apply to stdio transports, nor to deployments where the token is cryptographically bound to the client's origin at issuance (e.g., DPoP or mTLS-bound tokens).",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-confused-deputy-replay-when-http-native-mcp-transport-severs-origin-binding-from-capability-scope.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-confused-deputy-replay-when-http-native-mcp-transport-severs-origin-binding-from-capability-scope.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-confused-deputy-replay-when-http-native-mcp-transport-severs-origin-binding-from-capability-scope.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2724,
    "python_slice_tokens": 467,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"a stolen token.\" It is the **decoupling of two authorization dimensions that the transport silently treats as independent and the application silently treats as equivalent**: (1) *origin binding* — who the browser/agent believes it is talking to, enforced by `Origin`/`Host`/CORS and DNS; and (2) *capability scope* — what the bearer token ...",
    "what_was_observed": "An MCP server was deployed behind a reverse proxy at `https://mcp.internal.example/tools`. It enforced: - `Origin` allowlist: only `https://app.example` permitted (CORS preflight + `Origin` header check). - Bearer capability tokens: JWTs with `aud: \"mcp.internal.example\"` and `scope: \"tools:invoke\"`, minted by an OAuth AS for the `app.example` front-end. The intended flow: `app.example` (a browser SPA) obtains a toke...",
    "condition_of_validity": "The confused-deputy replay is only possible when **all** of the following hold simultaneously. Remove any one and the attack surface collapses: 1. **Bearer semantics without proof-of-possession.** The token is a plain bearer string; possession is sufficient. If the token were DPoP-bound (RFC 9449) or mTLS-bound, the attacker's induced request would fail at t...",
    "decision_boundary": "The boundary is not \"is the token valid\" but \"**was this specific instruction authorized to be paired with this specific token at this specific origin?**\" An instance must treat the following as the decision boundary: - **Allow** when the token carries a proof-of-possession binding (`cnf.jkt` for DPoP, or a client certificate thumbprint) that the presenting ...",
    "operational_effect": "The practical consequence is that **origin allowlisting and audience validation are necessary but not sufficient for HTTP-native MCP**, and an agent operating under this transport must assume that any `tools/call` it emits may be replayed by an attacker who has influenced its instruction channel. The architectural guardrails that bound the failure: 1. **Proo..."
  },
  "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": "504d8ea6f16ee165dd9c723e88e4dec38326ed6c9b22ba703124446544bf3e63",
    "verified_classes": [
      "ConfusedDeputyError",
      "CapabilityToken",
      "McpRequest"
    ],
    "verified_functions": [
      "_verify_dpop",
      "authorize",
      "handle_tools_call"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 6,
    "raised_exceptions": [
      "ConfusedDeputyError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib",
      "hmac",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
