ZeroHour

CVE-2026-81315

niche

Origin Validation Error in ash-project ash_ai allows MCP DNS-rebinding bypass

CVSS 4.0
7.4 high
EPSS
<1%p9
Published
()
Modified
AI analysis

CVE-2026-81315 is an origin validation error (CWE-346) in the MCP server shipped with the Elixir package ash-project ash_ai, leaving it open to DNS-rebinding attacks. In AshAi.Mcp.Server, when the default allowed_origins: nil is in effect, origin_allowed?/3 accepts an origin if uri.host equals conn.host and the forwarded scheme is https, but both values are attacker-controlled because conn.host is taken from the Host header and the scheme is read from the raw x-forwarded-proto header with no trusted-proxy check. A malicious web page can therefore use DNS rebinding so the browser sends an attacker-matching Host, and its JavaScript can set X-Forwarded-Proto: https, passing the check with no TLS or proxy involved. The attacker gains the ability to issue cross-site requests to the victim's local MCP server with that user's actor, effectively acting as the authenticated user. Affected are deployments running the ash_ai MCP server in versions from 0.8.0 before 1.0.0; exploitation is not currently known (EPSS 0.2%, not in CISA KEV, no public PoC).

What to do: Upgrade ash_ai to 1.0.0 or later, which trusts only localhost origins by default and requires an explicit allowed_origins allowlist for any other origin. As interim mitigation, configure an explicit allowed_origins allowlist and only honor X-Forwarded-Proto from trusted proxies, and confirm whether your MCP server is reachable from a browser at all, since only browser-reachable deployments are meaningfully exposed.

Affected
ash-project ash_aifrom 0.8.0 before 1.0.0 (>= 0.8.0, < 1.0.0)
Estimated exposure
nichelikely no more than a few thousand installations (niche Elixir package newly added in the 0.8.x line) — ash_ai is a recently introduced package in the niche Ash/Elixir ecosystem whose MCP server typically runs locally for individual developers or small application deployments, and no published install counts exist, so the affected population…

Order-of-magnitude estimate by the model from install counts, market share and public scan data it knows; verify before quoting.

Description

Origin Validation Error vulnerability in ash-project ash_ai allows a malicious web page to bypass the MCP server's DNS-rebinding protection and issue cross-site requests to a user's local MCP server with that user's actor. In AshAi.Mcp.Server, with the default allowed_origins: nil, origin_allowed?/3 accepts an origin when uri.host == conn.host and the forwarded scheme is https. Both values are attacker-controlled: conn.host comes from the Host header and the scheme is read from the raw x-forwarded-proto header with no trusted-proxy check. Under DNS rebinding the browser sends the attacker's origin and a matching host, and page JavaScript may set X-Forwarded-Proto: https, so the check passes with no TLS or proxy involved. The fix trusts only localhost origins by default; other origins require an explicit allowed_origins allowlist. This issue affects ash_ai: from 0.8.0 before 1.0.0.

Weakness
CWE-346
Vector
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

In the news

No ingested article mentions this CVE yet.