CVE-2026-42559: Rmcp Rmcp Streamable HTTP Server Transport Vulnerability

HIGH
Advisory Identifier: GHSA-89vp-x53w-74fx
CVSS 8.8
CWE-350 CWE-346
Published
Advisory Summary

CVE-2026-42559 is a HIGH (CVSS 8.8) rmcp streamable http server transport vulnerability (CWE-350: Reliance on Reverse DNS Resolution for a Security-Critical Action) affecting Rmcp libraries in the crates.io ecosystem. The issue involves rmcp streamable http server transport has a dns rebinding vulnerability. Remediation is available by upgrading affected packages to version 1.4.0.

CVE-2026-42559 at a Glance

CVE Identifier CVE-2026-42559
GHSA Identifier GHSA-89vp-x53w-74fx
Severity HIGH
CVSS v3.1 Base Score 8.8
CWE Classification CWE-350: Reliance on Reverse DNS Resolution for a Security-Critical Action
Affected Product Rmcp
Package Ecosystem crates.io
Published Date
Last Updated

Security Impact

CVSS: 8.8

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction Required (UI:R)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability High (A:H)

How to Fix CVE-2026-42559

To remediate this vulnerability, upgrade all affected Rmcp dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

rmcp fixed: 1.4.0
Upgrade rmcp to 1.4.0
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for rmcp

How to Check if You Are Affected

To determine whether your application is affected by CVE-2026-42559, inspect your project dependencies for Rmcp:

inspect dependencies for rmcp

Analyze the terminal output to locate any version of Rmcp in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.4.0), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-350: Reliance on Reverse DNS Resolution for a Security-Critical Action, where the product performs reverse dns resolution on an ip address to obtain the hostname and make a security decision, but it does not properly ensure that the ip address is truly associated with the hostname. In Rmcp, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

## Summary Prior to version 1.4.0, the `rmcp` crate's Streamable HTTP server transport (`crates/rmcp/src/transport/streamable_http_server/`) did not validate the incoming `Host` header. This allowed a malicious public website, via a DNS rebinding attack, to send authenticated requests to an MCP server running on the victim's loopback or private-network interface — violating the MCP specification's [transport security guidance](https://modelcontextprotocol.io/specification/2025-06-18/basic/transports#security-warning). ## Impact An attacker who convinces a victim to visit a malicious page can: - Enumerate and invoke any tool exposed by a locally-running rmcp-based MCP server. - Read resources, prompts, and any state accessible via the MCP session. - Trigger side effects (file writes, shell execution, API calls, etc.) limited only by what tools the victim's server exposes. Because MCP servers frequently run with the user's privileges and expose developer tooling (filesystems, shells, browser control, language servers, etc.), the practical impact can extend to arbitrary code execution on the victim's machine. ## Affected Versions `rmcp < 1.4.0` — all prior releases of the Streamable HTTP server transport. Non-HTTP transports (stdio, child-process) are not affected. ## Patched Versions `rmcp >= 1.4.0` (current: 1.5.1). ## Patch Fixed in [PR #764](https://github.com/modelcontextprotocol/rust-sdk/pull/764) (commit `8e22aa2`), released as v1.4.0 on 2026-04-09: - `StreamableHttpServerConfig::allowed_hosts` now defaults to a loopback-only allowlist: `["localhost", "127.0.0.1", "::1"]`. - All incoming HTTP requests pass through `validate_dns_rebinding_headers()`, which parses the `Host` header and returns HTTP 403 if the host is not on the allowlist. - Public deployments can configure an explicit allowlist via `StreamableHttpService::with_allowed_hosts(...)`, or opt out (not recommended without an upstream reverse proxy that validates `Host`) via `disable_allowed_hosts()`. This fix validates the `Host` header only. `Origin` header validation is tracked as a defense-in-depth follow-up in [#822](https://github.com/modelcontextprotocol/rust-sdk/issues/822) and is not required to block the DNS rebinding attack described here — the browser cannot forge the Host header sent to the rebound server. ## Workarounds for Unpatched Users - Upgrade to `rmcp >= 1.4.0`. - If upgrade is not possible, place the MCP server behind a reverse proxy (e.g. nginx, Caddy) configured to reject requests whose `Host` header is not one of your expected hostnames. - Do not bind the MCP server to `0.0.0.0` without such a proxy. ## Resources - PR: https://github.com/modelcontextprotocol/rust-sdk/pull/764 - Issue: https://github.com/modelcontextprotocol/rust-sdk/issues/815 - Follow-up (Origin validation): https://github.com/modelcontextprotocol/rust-sdk/issues/822 - MCP transport security guidance: https://modelcontextprotocol.io/specification/2025-06-18/basic/transports#security-warning ## Related advisories (same class of vulnerability) - TypeScript SDK: GHSA-w48q-cv73-mx4w - Python SDK: GHSA-9h52-p55h-vw2f - Go SDK: GHSA-xw59-hvm2-8pj6 - Java SDK: GHSA-8jxr-pr72-r468

CVE-2026-42559 Affected Rmcp Versions

1 component(s)
Fixed Versions:
1.4.0
Product / Package Ecosystem Affected Versions Fixed Version
rmcp
crates.io
< 1.4.0
1.4.0

References

Frequently Asked Questions

What is CVE-2026-42559?
CVE-2026-42559 is a security vulnerability in Rmcp involving rmcp Streamable HTTP server transport has a DNS rebinding vulnerability under CWE-350: Reliance on Reverse DNS Resolution for a Security-Critical Action.
Which Rmcp versions are affected?
Affected versions include releases prior to 1.4.0 across affected packages: rmcp.
What version fixes CVE-2026-42559?
Upgrading to 1.4.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is rmcp affected?
Yes, rmcp is affected in releases prior to 1.4.0. Upgrade your dependency to 1.4.0 or later.
What is the CVSS score of CVE-2026-42559?
CVE-2026-42559 has a CVSS v3.1 base score of 8.8 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H.
What CWE is associated with CVE-2026-42559?
CVE-2026-42559 is classified under CWE-350: Reliance on Reverse DNS Resolution for a Security-Critical Action (The product performs reverse DNS resolution on an IP address to obtain the hostname and make a security decision, but it does not properly ensure that the IP address is truly associated with the hostname.).
How can I check crates.io dependencies for CVE-2026-42559?
Run the dependency tree command: 'inspect dependencies for rmcp'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-89vp-x53w-74fx",
  "modified" : "2026-05-19T20:17:47Z",
  "published" : "2026-05-06T21:55:56Z",
  "aliases" : [ "CVE-2026-42559" ],
  "summary" : "rmcp Streamable HTTP server transport has a DNS rebinding vulnerability",
  "details" : "## Summary\n\nPrior to version 1.4.0, the `rmcp` crate's Streamable HTTP server transport (`crates/rmcp/src/transport/streamable_http_server/`) did not validate the incoming `Host` header. This allowed a malicious public website, via a DNS rebinding attack, to send authenticated requests to an MCP server running on the victim's loopback or private-network interface — violating the MCP specification's [transport security guidance](https://modelcontextprotocol.io/specification/2025-06-18/basic/transports#security-warning).\n\n## Impact\n\nAn attacker who convinces a victim to visit a malicious page can:\n\n- Enumerate and invoke any tool exposed by a locally-running rmcp-based MCP server.\n- Read resources, prompts, and any state accessible via the MCP session.\n- Trigger side effects (file writes, shell execution, API calls, etc.) limited only by what tools the victim's server exposes.\n\nBecause MCP servers frequently run with the user's privileges and expose developer tooling (filesystems, shells, browser control, language servers, etc.), the practical impact can extend to arbitrary code execution on the victim's machine.\n\n## Affected Versions\n\n`rmcp < 1.4.0` — all prior releases of the Streamable HTTP server transport. Non-HTTP transports (stdio, child-process) are not affected.\n\n## Patched Versions\n\n`rmcp >= 1.4.0` (current: 1.5.1).\n\n## Patch\n\nFixed in [PR #764](https://github.com/modelcontextprotocol/rust-sdk/pull/764) (commit `8e22aa2`), released as v1.4.0 on 2026-04-09:\n\n- `StreamableHttpServerConfig::allowed_hosts` now defaults to a loopback-only allowlist: `[\"localhost\", \"127.0.0.1\", \"::1\"]`.\n- All incoming HTTP requests pass through `validate_dns_rebinding_headers()`, which parses the `Host` header and returns HTTP 403 if the host is not on the allowlist.\n- Public deployments can configure an explicit allowlist via `StreamableHttpService::with_allowed_hosts(...)`, or opt out (not recommended without an upstream reverse proxy that validates `Host`) via `disable_allowed_hosts()`.\n\nThis fix validates the `Host` header only. `Origin` header validation is tracked as a defense-in-depth follow-up in [#822](https://github.com/modelcontextprotocol/rust-sdk/issues/822) and is not required to block the DNS rebinding attack described here — the browser cannot forge the Host header sent to the rebound server.\n\n## Workarounds for Unpatched Users\n\n- Upgrade to `rmcp >= 1.4.0`.\n- If upgrade is not possible, place the MCP server behind a reverse proxy (e.g. nginx, Caddy) configured to reject requests whose `Host` header is not one of your expected hostnames.\n- Do not bind the MCP server to `0.0.0.0` without such a proxy.\n\n## Resources\n\n- PR: https://github.com/modelcontextprotocol/rust-sdk/pull/764\n- Issue: https://github.com/modelcontextprotocol/rust-sdk/issues/815\n- Follow-up (Origin validation): https://github.com/modelcontextprotocol/rust-sdk/issues/822\n- MCP transport security guidance: https://modelcontextprotocol.io/specification/2025-06-18/basic/transports#security-warning\n\n## Related advisories (same class of vulnerability)\n\n- TypeScript SDK: GHSA-w48q-cv73-mx4w\n- Python SDK: GHSA-9h52-p55h-vw2f\n- Go SDK: GHSA-xw59-hvm2-8pj6\n- Java SDK: GHSA-8jxr-pr72-r468",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "crates.io",
      "name" : "rmcp"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "1.4.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/modelcontextprotocol/rust-sdk/security/advisories/GHSA-89vp-x53w-74fx"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/nubo-db/dynoxide/security/advisories/GHSA-fvh2-gm75-j4j7"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-42559"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/modelcontextprotocol/rust-sdk/issues/815"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/modelcontextprotocol/rust-sdk/issues/822"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/modelcontextprotocol/rust-sdk/pull/764"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/modelcontextprotocol/rust-sdk/commit/8e22aa2de28df5a285eed87c11cd89bf15fa90d3"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/modelcontextprotocol/rust-sdk"
  }, {
    "type" : "WEB",
    "url" : "https://modelcontextprotocol.io/specification/2025-06-18/basic/transports#security-warning"
  }, {
    "type" : "WEB",
    "url" : "https://rustsec.org/advisories/RUSTSEC-2026-0140.html"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-346", "CWE-350" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-05-06T21:55:56Z",
    "nvd_published_at" : "2026-05-14T15:16:46Z"
  }
}