CVE-2026-138406 — PostgreSQL psqlODBC
One of 3 PostgreSQL psqlODBC vulnerabilities published together by NVD: our article covers all of them.
WindowsOperating systemsDatabasesVulnerabilitiesResearch article
psqlODBC DLL Loading Vulnerability in PostgreSQL
| CVE | CVE-2026-138406 |
|---|---|
| Vendor and product | PostgreSQL psqlODBC |
| Published | November 29, 2026 20:05 UTC |
| Research cut-off | November 29, 2026 19:45 UTC |
| Sources reviewed | 2: NVD record (last modified 2026-11-29); CISA KEV catalog |
Executive summary
CVE-2026-138406 is a vulnerability in PostgreSQL's psqlODBC driver that allows local users to execute arbitrary code through a DLL loading issue [1]. The CVSS 3.1 score is 7.3 HIGH, scored by a secondary source [1]. The vulnerability affects versions up to and including 18.00.0007. The reviewed sources do not report exploitation [2]. The sources do not list a fixed version for this CVE [1].
Key points
- CVE-2026-138406 is a vulnerability in PostgreSQL's psqlODBC driver that allows local users to execute arbitrary code through a DLL loading issue [1].
- The CVSS 3.1 score is 7.3 HIGH, scored by a secondary source [1].
- The vulnerability affects versions up to and including 18.00.0007 [1].
- The reviewed sources do not report exploitation [2].
- The sources do not list a fixed version for this CVE [1].
Vulnerability identification
| CVE ID | Vendor | Product | CWE | CVSS 3.1 Score | Published Date | Last Modified Date | Record Status |
|---|---|---|---|---|---|---|---|
| CVE-2026-138406 | PostgreSQL | psqlODBC | CWE-427 | 7.3 HIGH | 2026-11-29 | 2026-11-29 | Received |
Vulnerability description
The psqlODBC driver relies on pgenlist.dll for MSDTC enlistment, which is loaded when an application engages in distributed transaction processing. On builds made with Visual C++ 14 or later, the DLL is loaded by name rather than by its path [1]. Windows then searches for the DLL in the application's directory, the current working directory, and the system's PATH environment variable. None of these locations correspond to the directory where the driver installs pgenlist.dll. Someone with a standard login who had permission to save files into one of these folders could drop a copy of their own pgenlist.dll there, and during the next MSDTC enlistment the code inside that DLL might execute with the application's account rights [1].
Attack surface and exploitation prerequisites
The CVSS score indicates the attack requires local access, low privileges, and user interaction [1]. The vulnerability only applies if the application never sets SQLATTRENLISTINDTC, since applications that never set it do not load pgenlist.dll [1].
Impact analysis
On a server, the application's account may hold greater permissions than the rights the attacker has on their own account [1].
Affected products and versions
| Affected Product | Fixed Version |
|---|---|
| PostgreSQL psqlODBC | not listed |
Exploitation and threat intelligence status
CVE-2026-138406 is not present in the CISA Known Exploited Vulnerabilities Catalog as of 2026-11-29 [2]. The reviewed sources do not report exploitation.
Detection and exposure assessment
To assess exposure, verify whether the installed psqlODBC version is equal to or earlier than 18.00.0007 [1].
Remediation
The sources do not specify a fixed version for this CVE. Updating to a fixed version is general guidance, not a source-based fact.
Remediation checklist
- Check if the installed version of psqlODBC is ≤ 18.00.0007 [1].
- The sources do not specify a fixed version for this CVE. Updating to a fixed version is general guidance, not a source-based fact.
Evidence gaps
- The sources do not describe the affected component's internals.
- The sources do not mention a workaround.
- The sources do not list a fixed version for this CVE.
- The sources do not describe the attack lifecycle or scenarios.
- The sources do not provide indicators of compromise.
References
- CVE-2026-138406 record. NIST National Vulnerability Database (NVD), 2026-11-29. https://nvd.nist.gov/vuln/detail/CVE-2026-138406. Accessed 2026-11-29.
- Known Exploited Vulnerabilities Catalog. Cybersecurity and Infrastructure Security Agency (CISA), 2026-11-29. https://www.cisa.gov/known-exploited-vulnerabilities-catalog. Accessed 2026-11-29.
Summary
psqlODBC uses pgenlist.dll, which is installed with the driver, for MSDTC enlistment. It loads the DLL the first time an application enlists. On builds made with Visual C++ 14 or later, it loaded the DLL by name, not by its path. Windows then searched the application's directory, the current directory and the directories on PATH, and none of them is where the driver installs pgenlist.dll. So another local user who could write to one of those directories could put their own pgenlist.dll there. The next time the application enlisted in MSDTC, that DLL's code ran in the application, under the application's account. On a server, that account can have more privileges than the attacker's own. An application that never sets SQL_ATTR_ENLIST_IN_DTC does not load pgenlist.dll and is unaffected. Only the Windows builds of the driver use pgenlist.dll. Versions up to and including psqlODBC 18.00.0007 are affected.
Severity breakdown
High · 7.3
An attacker with a normal user account can exploit this with local access if a user is tricked into an action.
- Attack from
- local access (a logged-in user, or a malicious file opened on the device)
- Attack complexity
- low (no special conditions)
- Login needed
- yes, a normal user account
- User action needed
- yes, someone must click, open or visit something
- Scope
- stays within the vulnerable component
- Impact
- high on confidentiality, integrity and availability
Weakness
- CWE-427: Uncontrolled Search Path Element
Affected and fixed versions
| Product | Affected versions | Fixed in |
|---|---|---|
| PostgreSQL psqlODBC | ≤ 18.00.0007 | — |
References by type
Vendor advisories
Other references
Affected
- PostgreSQL psqlODBC
Frequently asked questions
What is CVE-2026-138406?
CVE-2026-138406 is a vulnerability in PostgreSQL's psqlODBC driver that allows local users to execute arbitrary code through a DLL loading issue. The CVSS 3.1 score is 7.3 HIGH, scored by a secondary source. The vulnerability affects versions up to and including 18.00.0007. The reviewed sources do not report exploitation. The sources do not list a fixed version for this CVE. Weakness type: Uncontrolled Search Path Element (CWE-427).
How severe is CVE-2026-138406?
CVE-2026-138406 has a CVSS 3.1 base score of 7.3 (high), from the CNA. An attacker with a normal user account can exploit this with local access if a user is tricked into an action.
Is CVE-2026-138406 being exploited?
Not as far as is known: CVE-2026-138406 is not in CISA's Known Exploited Vulnerabilities catalog as of November 29, 2026.
Which versions are affected by CVE-2026-138406?
PostgreSQL psqlODBC ≤ 18.00.0007.
How do I fix CVE-2026-138406?
Check if the installed version of psqlODBC is ≤ 18.00.0007. The sources do not specify a fixed version for this CVE. Updating to a fixed version is general guidance, not a source-based fact.
Timeline & sources
References
Related vulnerabilities & news
- psqlODBC Memory Corruption Vulnerability in PostgreSQL
- psqlODBC Connection String Parsing Flaw Enables Remote Code Execution
- psqlODBC Case Sensitivity Flaw Enables Privilege Escalation
- psqlODBC SQL Injection Vulnerability in PostgreSQL
- PowerPanel Business Vulnerabilities Exploited in Targeted Cyberattack