Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessHold PostgreSQL role with mysql_fdw USAGE
-
DeliverySet init_command or ssl_key/mysql_default_file option
-
ExploitArbitrary SQL runs on remote MySQL at connect
-
ExecutionExecutes under other users' shared-server mappings
-
ImpactRead PostgreSQL host files and redirect connection
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A06:2025 - Insecure Design
ASVS 5.0
V8 - Authorization Least privilege enforcement
MITRE ATT&CK
1 technique across 1 tactic: Privilege Escalation The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires an authenticated PostgreSQL role (PR:L) that has been granted USAGE on the mysql_fdw foreign data wrapper; it is not remote-unauthenticated. The attacker must be able to set the security-sensitive options init_command, mysql_default_file, ssl_key, ssl_cert, ssl_ca or ssl_capath on a foreign server or user mapping on a pre-2.10.0 mysql_fdw install. The cross-user init_command impact specifically requires a SHARED foreign server where other users' mappings also open connections (this maps to the CVSS AT:P attack requirement); the server-side file-read and connection-redirection impacts need only the attacker's own mapping. Limiting factors: the vulnerability is closed in mysql_fdw 2.10.0, which restricts these options to superusers, and risk is confined to deployments that expose the wrapper to non-superuser roles - single-tenant or superuser-only installs are not meaningfully exposed. |
| Impact | This is a medium-severity privilege-management flaw (CVE-2026-62152, CVSS 4.0 base 5.8, CWE-269), not a top-priority emergency. The supplied CVSS 4.0 vector (AV:N/AC:L/AT:P/PR:L/UI:N) confirms the attacker must already hold a low-privilege authenticated PostgreSQL role (PR:L) with USAGE on the mysql_fdw foreign data wrapper, and that a specific attack requirement exists (AT:P) - namely a shared foreign server where other users' mappings also connect, needed for the cross-user init_command abuse. The vector models low direct impact to the PostgreSQL server (VC:L/VI:N/VA:N) but high impact to subsequent systems (SC:H/SI:H/SA:H), reflecting arbitrary SQL execution against the remote MySQL server and server-side file reads. Exploitation status is 'no public exploit identified at time of analysis' - there is no KEV listing, no POC reference, and no EPSS score in the input, so there is no signal of active or widespread exploitation. The vuln.today decision label is 'this_month' (not act_now/emergency), consistent with an authenticated, precondition-dependent issue rather than a drive-by remote. No signals conflict here; the limiting factor is the PR:L requirement - an attacker needs an existing database role with FDW USAGE, which bounds real-world risk to multi-tenant PostgreSQL deployments that expose mysql_fdw to non-superusers. |
| Exploit ScenarioDerived | In a shared-hosting or multi-tenant PostgreSQL deployment, a non-superuser role that holds USAGE on the mysql_fdw wrapper sets init_command on a foreign server or user mapping; this SQL then executes on the remote MySQL server at every connection, including connections opened under other users' mappings to that shared foreign server. The same role can set ssl_key, ssl_cert, ssl_ca, ssl_capath or mysql_default_file to filenames on the PostgreSQL host, causing server-side reads of local files and redirection of the MySQL connection. No public exploit code is identified; exploitation requires an existing low-privilege database role rather than remote unauthenticated access. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Nov 25, 2026
In mysql_fdw before 2.10.0, a PostgreSQL role that holds only USAGE on the mysql_fdw foreign data wrapper - not superuser rights - can supply security-sensitive connection options that the extension should have reserved for superusers. Such a role can set init_command, which executes arbitrary SQL against the remote MySQL server on every connection opened through a shared foreign server, including connections made with other users' mappings, and can point mysql_default_file, ssl_key, ssl_cert, ssl_ca and ssl_capath at files on the PostgreSQL server host, enabling server-side file reads and redirection of the connection to a host of the attacker's choosing. The flaw is a privilege-management weakness (CWE-269) rated medium (CVSS 4.0 base 5.8; independently assessed CVSS 3.1 AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:N), requiring an already-authenticated role with wrapper USAGE; exploitation is not confirmed in the wild and no public exploit has been identified at time of analysis, and mysql_fdw 2.10.0 restricts all six options to superusers.
RemediationAI
Vendor-released patch: upgrade to mysql_fdw 2.10.0 (REL-2_10_0), which restricts init_command, mysql_default_file, ssl_key, ssl_cert, ssl_ca and ssl_capath to superusers; see the advisory at https://www.enterprisedb.com/docs/security/advisories/cve202662152/ and the release at https://github.com/EnterpriseDB/mysql_fdw/releases/tag/REL-2_10_0. Before upgrading, audit existing foreign servers and user mappings for values of these six options, since the release notes state that foreign servers using the restricted options and created by non-superusers will be rejected when altered and must be re-created or altered by a superuser; expect transient failures for those servers until an administrator rebuilds them. The same release also always adds NO_BACKSLASH_ESCAPES to the remote session sql_mode and re-imports foreign schema column defaults as string literals, so re-apply expression defaults such as CURRENT_TIMESTAMP after import. Where upgrading cannot be done immediately, revoke USAGE on the mysql_fdw wrapper from non-superuser roles (or drop the wrapper from roles that do not need it), accepting that those roles can no longer create or query mysql_fdw foreign tables, and replace shared foreign servers used by multiple roles with per-role servers so no mapping can influence another user's connections; also review grants on existing servers and mappings, because a role that already set init_command or file-path options keeps that configuration until a superuser changes it.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
mysql_fdw is the EnterpriseDB foreign data wrapper that lets PostgreSQL and EDB Postgres Advanced Server query MySQL tables through the SQL/MED foreign data wrapper API. Connection parameters are supplied as key/value options on foreign servers and user mappings, and they are funneled through the extension's validator and then used when the wrapper opens a libmysqlclient session. The root cause is improper privilege management (CWE-269): the option validator accepted init_command, mysql_default_file, ssl_key, ssl_cert, ssl_ca and ssl_capath from any role with USAGE on the wrapper, even though those options influence what SQL runs on the remote server and which local files and TLS material the backend reads. Because init_command is applied at connection establishment, its effect is not scoped to the option-setter's own queries when other users' mappings open connections on the same shared foreign server, which is the basis for the CVSS 4.0 AT:P requirement and the scope change (S:C) in the independent assessment. The affected CPE is cpe:2.3:a:enterprisedb:mysql_foreign_data_wrapper_(mysql_fdw):*:*:*:*:*:*:*. Version 2.10.0 changes the validator so only superusers may set these six options, and its release notes also state that foreign servers created by non-superusers with the now-restricted options will be rejected when altered.
Know when PostgreSQL gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:L/VI:N/VA:N/SC:H/SI:H/SA:H
Attacker needs a low-privilege role with FDW USAGE (PR:L) reachable over the DB connection (AV:N/AC:L); impact crosses to the remote MySQL server and host files (S:C) via arbitrary SQL and file reads (C:H/I:H).
Primary rating from Vendor (EDB).
CVSS VectorVendor: EDB
DescriptionCVE.org
mysql_fdw accepts several security-sensitive connection options from roles that are not superusers. A role with USAGE on the mysql_fdw foreign data wrapper can set init_command, which runs arbitrary SQL on the remote MySQL server at every connection, including connections made with other users' mappings on a shared foreign server. The same role can set mysql_default_file, ssl_key, ssl_cert, ssl_ca and ssl_capath, which name files read from the PostgreSQL server host, allowing server-side file reads and connection redirection. The issue is fixed in mysql_fdw 2.10.0. From mysql_fdw 2.10.0, only superusers can set init_command, mysql_default_file, ssl_key, ssl_cert, ssl_ca and ssl_capath.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Privilege escalation occurs when an attacker leverages flaws in access control mechanisms to gain permissions beyond what they were originally granted.
More in PostgreSQL
View allPostgreSQL libpq functions PQescapeLiteral(), PQescapeIdentifier(), PQescapeString(), and PQescapeStringConn() improperl
An issue was discovered in Appsmith before 1.52. Rated critical severity (CVSS 9.8), this vulnerability is remotely expl
Argument injection vulnerability in PostgreSQL 9.2.x before 9.2.4, 9.1.x before 9.1.9, and 9.0.x before 9.0.13 allows re
Unauthenticated arbitrary file write in Splunk Enterprise (below 10.2.4 and 10.0.7) and Splunk Cloud Platform (below 10.
Unauthenticated SQL injection in Sangoma Switchvox SMB Edition 8.3 (build 104997) lets remote attackers execute arbitrar
PostgreSQL versions before 9.2.22, 9.3.18, 9.4.13, 9.5.8 and 9.6.4 are vulnerable to incorrect authentication flaw allow
The build_tablename function in pgsql.c in the PostgreSQL (aka pgsql) extension in PHP through 5.6.7 does not validate t
A vulnerability in the h2oai/h2o-3 REST API versions 3.46.0.4 allows unauthenticated remote attackers to execute arbitra
In PostgreSQL 9.3 through 11.2, the "COPY TO/FROM PROGRAM" function allows superusers and users in the 'pg_execute_serve
Unauthenticated SQL injection in Vendure Shop API allows remote attackers to execute arbitrary SQL commands against the
Parse Server is an open source http web server backend. Rated critical severity (CVSS 10.0), this vulnerability is remot
Hard-coded default PostgreSQL credentials shipped in the docker-compose.yaml of langgenius Dify through version 1.5.1 al
EUVD-2026-135559
GHSA-gv24-j96j-h75w
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB