CVE-2026-125320: pgEdge Postgres MCP Server DNS rebinding flaw fixed in 1.1.0

A missing Origin header check in pgEdge Postgres MCP Server allowed DNS rebinding attacks that could expose database schemas and query results to malicious web pages.

Christopher Ort
By Christopher Ort · 3 min read
Share
A developer's laptop screen showing a web browser and a terminal window running a database server, photographed from over the shoulder in a home office
Image: AI-generated, i10X
On this page
  1. Quick Take
  2. In plain English
  3. What happened
  4. What you should do
  5. What it means
  6. Sources

A security flaw in pgEdge Postgres MCP Server allowed attackers to exploit DNS rebinding to read database schemas and query results from a user’s locally running server. The vulnerability, tracked as CVE-2026-125320, affected all versions prior to 1.1.0 when the HTTP transport was enabled.

i10X Quick Take

Quick Take

  1. What: pgEdge Postgres MCP Server did not validate the Origin header on HTTP requests, enabling DNS rebinding attacks.
  2. Who is affected: Users running version 1.0.0 or earlier with HTTP transport enabled on a machine that also runs a browser.
  3. What to do: Upgrade to version 1.1.0 or later. Deployments serving the web client under a real hostname must configure http.allowed_origins or PGEDGE_HTTP_ALLOWED_ORIGINS.
  4. Severity: Medium (CVSS 5.3), requires user interaction and high attack complexity.
  5. Status: Patched in version 1.1.0 released September 4, 2026.

In plain English

The pgEdge Postgres MCP Server is a developer tool that lets AI assistants query PostgreSQL databases. A security hole let attackers trick a user’s web browser into connecting to the server running on their own computer and reading database information. The attacker would point a domain they control at the user’s local machine, and the browser would treat the local server as part of the attacker’s site. This only affected users who turned on the HTTP transport feature and visited an attacker’s website.

What you should do: If you use this tool with HTTP transport enabled, upgrade to version 1.1.0, otherwise you can ignore this.

What happened

The pgEdge Postgres MCP Server enables SQL queries against PostgreSQL databases through Model Context Protocol compatible clients. Prior to version 1.1.0, the HTTP transport did not validate the Origin header on incoming requests.

An attacker could exploit this by serving a web page from a domain they control, then repointing that domain to resolve to 127.0.0.1. When a user visited the attacker’s page, the browser would connect to the user’s own machine while still treating the page as belonging to the attacker’s domain. Because the request appeared same-origin to the browser, no CORS preflight was sent and the page could read responses from the locally running server.

The practical exposure was that a malicious page could reach a locally running server and issue MCP requests to read schemas and execute queries against configured databases. The issue affected deployments with the HTTP transport enabled on a machine that also ran a browser. The default stdio transport was not reachable through this attack path.

The vulnerability was documented in issue #231 on August 6, 2026, and fixed in pull request #232 on August 7, 2026. The fix was released in version 1.1.0 on September 4, 2026.

What you should do

Upgrade to version 1.1.0 or later. The fixed version validates the Origin header and refuses unexpected origins with HTTP 403 Forbidden.

With no origins configured, the server accepts loopback origins only (localhost, 127.0.0.1, ::1, either scheme, any port), which covers local use and the bundled web client unchanged.

Deployments that serve the web client under a real hostname must list that origin in the new http.allowed_origins setting or the PGEDGE_HTTP_ALLOWED_ORIGINS environment variable. Without this configuration, browser requests will be refused. Listing any origin replaces the loopback default rather than adding to it.

Requests carrying no Origin header are unaffected, so command line clients, scripts and other non-browser callers need no change.

As a workaround, do not enable the HTTP transport. The default stdio transport is not reachable from a browser. Where HTTP is required, bind the listener to an interface a browser on the same machine cannot reach, or place it behind a proxy that rejects requests carrying an unexpected Origin.

What it means

The Model Context Protocol specification requires servers using the Streamable HTTP transport to validate the Origin header on all incoming connections to prevent DNS rebinding attacks. The pgEdge Postgres MCP Server did not implement this requirement in versions prior to 1.1.0.

The vulnerability is rated Medium severity with a CVSS score of 5.3 (CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N). The attack complexity is high and requires user interaction, but no privileges are required and the confidentiality impact is high.

The fix adds origin-validation middleware that wraps the entire HTTP handler chain, covering /health, the LLM proxy routes, and the MCP endpoint. Validation runs ahead of authentication so hostile pages are refused before any credential is examined. The MCP endpoint returns a JSON-RPC error response with a null id when rejecting a request, which the transport specification explicitly permits.

Sources

Christopher Ort

Christopher Ort

Christopher Ort handles SEO, AI agent workflows and PR & partnerships at i10x.ai, the all-in-one AI workspace built by i10X Global Pte. Ltd. in Singapore. He is a graduate of Friedrich-Alexander-Universität Erlangen-Nürnberg (FAU). He is the author of “The Style Penalty”, a study published on SSRN that analyses 1,576 evaluation decisions by four frontier AI models to show how AI-written CVs fare in automated hiring screens; the research has been covered by heise online and t3n.

Editor's picks

  1. CVE-2026-132121: Any website can hijack a local Supergateway and run your MCP tools
  2. CVE-2026-132122: agentic-radar scans can leak your OpenAI API key to a malicious repository
  3. CVE-2026-119220: Dokan MCP endpoint regex flaw lets attackers bypass WooCommerce permissions
  4. Reflection AI Gates Laser, Its Autonomous Penetration Testing Agent, Behind a Trusted Access Program
  5. BrightAI Raises $97 Million to Replace Scheduled Infrastructure Inspections With Physical AI