psqlODBC ODBC escape parser stack buffer overflow
Summary
| CVE | CVE-2026-120061 |
|---|---|
| State | PUBLISHED |
| Assigner | PostgreSQL |
| Source Priority | CVE Program / NVD first with legacy fallback |
| Published | 2026-11-02 19:18:03 UTC |
| Updated | 2026-11-02 20:17:39 UTC |
| Description | The psqlODBC parser for ODBC escape sequences in application SQL text writes the argument offsets of a {fn} escape into a fixed 16-entry stack array without a bound and does not initialize the array. An escape with too many arguments overflows the stack, and a reference to an unsupplied argument copies arbitrary bytes into the query. The copy of a {d}, {t}, {ts}, or {escape} body also writes one byte past a 128-byte stack buffer. An application that forwards untrusted SQL text to the driver exposes its process to memory corruption. Versions before psqlODBC 18.00.0006 are affected. |
Risk And Classification
Primary CVSS: v3.1 7.5 HIGH from f86ef6dc-4d3a-42ad-8f28-e6d5547a5007
CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
Problem Types: CWE-121 | CWE-193 | CWE-457 | CWE-121 CWE-121 Stack-based Buffer Overflow | CWE-193 CWE-193 Off-by-one Error | CWE-457 CWE-457 Use of Uninitialized Variable
| Version | Source | Type | Score | Severity | Vector |
|---|---|---|---|---|---|
| 3.1 | f86ef6dc-4d3a-42ad-8f28-e6d5547a5007 | Secondary | 7.5 | HIGH | CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H |
| 3.1 | CNA | CVSS | 7.5 | HIGH | CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H |
CVSS v3.1 Breakdown
Attack Vector
NetworkAttack Complexity
HighPrivileges Required
LowUser Interaction
NoneScope
UnchangedConfidentiality
HighIntegrity
HighAvailability
HighCVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
Vendor Declared Affected Products
| Source | Vendor | Product | Version | Platforms |
|---|---|---|---|---|
| CNA | PostgreSQL | PsqlODBC | affected 18.00.0006 custom | Not specified |
References
| Reference | Source | Link | Tags |
|---|---|---|---|
| github.com/postgresql-interfaces/psqlodbc/security/advisories/GHSA-hfm6-... | f86ef6dc-4d3a-42ad-8f28-e6d5547a5007 | github.com | |
| CVE Program record | CVE.ORG | www.cve.org | canonical |
| NVD vulnerability detail | NVD | nvd.nist.gov | canonical, analysis |
No vendor comments have been submitted for this CVE.
Additional Advisory Data
Solutions
CNA: Upgrade to psqlODBC 18.00.0006 or later. The argument offset array is initialized and bounded, and the escape body copy reserves room for the terminator.
Workarounds
CNA: Do not pass SQL text from untrusted sources to the driver, or reject text containing ODBC escape sequences ({fn ...}, {d ...}, {t ...}, {ts ...}, {escape ...}) before it reaches the driver.
There are currently no legacy QID mappings associated with this CVE.