CVE-2026-138406

Another local user's pgenlist.dll runs in the application

Published Nov 29, 2026 CVSS 3.1 · 7.3 High EPSS n/a KEV · Not listed
Description
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.

Analysis

AI-generated

Technical impact

The PostgreSQL psqlODBC driver for Microsoft Windows loads a helper DLL called pgenlist.dll during database enlistment in the Microsoft Distributed Transaction Coordinator. Because the driver is built with Visual C++ 14 or later, the DLL is located by name rather than by its installation path. As a result, the operating system searches standard directories such as the application directory, the current working directory, and the PATH environment for the DLL. A local user who has write access to any of these directories can place a malicious DLL that takes the name pgenlist.dll. When a database connection subsequently enlists in MSDTC, the driver loads the attacker‐supplied DLL and its code runs inside the application process, under the application’s user account. If that account has higher privileges than the attacker, the vulnerability can be used for local privilege escalation.

Affected Systems

The issue affects the Windows builds of the PostgreSQL psqlODBC driver (PostgreSQL:psqlODBC). All releases up to and including version 18.00.0007 are susceptible. The problem does not impact non‑Windows builds or applications that do not enable MSDTC enlistment, since the DLL is not loaded in those cases.

Risk and Exploitability

The vulnerability has a CVSS score of 7.3, indicating moderate to high severity. EPSS is not available, and the vulnerability is not listed in CISA’s KEV catalog, so current exploitation activity is unknown. However, the attack vector requires local user privileges to write to a DLL search path directory. Once exploited, the attacker gains the privileges of the application's process, which on a server may be significantly elevated. Given the severity rating and the potential for privilege escalation, the risk is considerable for environments that use this driver and allow local write access to the relevant directories.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Update psqlODBC to version 18.00.0008 or later, which removes the vulnerable DLL loading logic.
  • If an immediate update is not possible, modify application configuration to disable MSDTC enlistment by ensuring SQL_ATTR_ENLIST_IN_DTC is not set or set to false, thereby preventing the driver from loading pgenlist.dll.
  • Restrict write permissions to the application directory, the current working directory, and any directories included in the system PATH so that local users cannot replace pgenlist.dll.

Generated by OpenCVE AI on November 29, 2026 at 19:21 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
First Time appeared Postgresql
Postgresql psqlodbc
Vendors & Products Postgresql
Postgresql psqlodbc
Type Values Removed Values Added
Description 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.
Title Another local user's pgenlist.dll runs in the application
Weaknesses CWE-427
References
Metrics cvssV3_1

{'score': 7.3, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H'}

Weaknesses
  • CWE-427

    Uncontrolled Search Path Element

Sources

Status
PUBLISHED
Assigner
PostgreSQL
Published
Updated
Nov 29, 2026, 6:01 PM
Reserved
Nov 29, 2026, 4:10 PM
Status
Received
Published
Nov 29, 2026, 7:17 PM
Modified
Nov 29, 2026, 7:17 PM