{"id":"CVE-2026-120062","kind":"vulnerability","aliases":["CVE-2026-120062"],"related":[],"title":"psqlODBC: SQLSpecialColumns lets untrusted names run arbitrary SQL","description":"SQLSpecialColumns in psqlODBC splices the table and schema names it receives into its catalog query without escaping them, while the other catalog functions escape them. An application that passes an untrusted table or schema name to SQLSpecialColumns lets the caller execute arbitrary SQL with the privileges of the connection. Versions before psqlODBC 18.00.0006 are affected.","summary":"psqlODBC, the PostgreSQL ODBC driver, puts table and schema names passed to SQLSpecialColumns into a catalog query without escaping them. An attacker who controls those names can run arbitrary SQL with the privileges of the database connection.","severity":"high","cvss":7.5,"epss":null,"exploited":false,"exploited_at":null,"products":[],"ecosystems":[],"tags":["c","node","odbc","package","postgresql","psqlodbc","python"],"not_affected_if":["fixed-table-names","no-sqlspecialcolumns-calls"],"how_to_check":"- Check the installed psqlODBC driver version (`psql --version` does not report it; look at the driver package or the ODBC driver entry in `odbcinst.ini`).\n- Search application code for calls to `SQLSpecialColumns` and check whether table or schema names come from user input.","fix":"- psqlODBC: move to `18.00.0006` or later.","status":"open","published_at":"2026-11-02T19:18:03+00:00","first_seen_at":"2026-11-02T19:24:40+00:00","triaged_at":"2026-11-02T19:26:41+00:00","updated_at":"2026-11-02T19:26:41+00:00","category":"package","confidence":0.6,"triage":{"at":"2026-11-02T19:26:41Z","model":"claude-haiku-5-5","output":{"fix":"- psqlODBC: move to `18.00.0006` or later.","reach":"unknown","title":"psqlODBC: SQLSpecialColumns lets untrusted names run arbitrary SQL","impact":"high","summary":"psqlODBC, the PostgreSQL ODBC driver, puts table and schema names passed to SQLSpecialColumns into a catalog query without escaping them. An attacker who controls those names can run arbitrary SQL with the privileges of the database connection.","audience":"developers","category":"package","nicknames":[],"who_cares":["psqlodbc","postgresql","odbc","python","c","node"],"confidence":0.6,"fix_status":"available","needs_auth":"unknown","worst_case":"Arbitrary SQL runs with the connection's database privileges","analyst_note":"Confirm the exact affected version range and whether authentication is needed; the vendor advisory linked in the sources was not read.","how_to_check":"- Check the installed psqlODBC driver version (`psql --version` does not report it; look at the driver package or the ODBC driver entry in `odbcinst.ini`).\n- Search application code for calls to `SQLSpecialColumns` and check whether table or schema names come from user input.","plain_action":"","needs_analyst":true,"not_affected_if":["fixed-table-names","no-sqlspecialcolumns-calls"],"who_is_affected":"Applications that use the psqlODBC driver and pass table or schema names to SQLSpecialColumns that an untrusted party can influence. Applications that only use fixed, internal names, or that do not call SQLSpecialColumns, are not exposed to this flaw. The sources do not say whether a specific default configuration is required.","user_interaction":"no","needs_special_setup":"unknown","severity_if_unknown":"high"},"cost_usd":0.000726,"input_tokens":4166,"output_tokens":618,"severity_before":"high"},"analyst_status":null,"analyst_note":null,"search":"'-120062':11A,14A '-2026':10A,13A '18.00.0006':111C 'affect':113C 'applic':85C 'arbitrari':7A,50B,100C 'attack':43B 'c':15B 'caller':98C 'catalog':37B,72C,80C 'connect':58B,107C 'control':45B 'cve':9A,12A 'databas':57B 'driver':26B 'escap':40B,75C,82C 'execut':99C 'function':81C 'let':3A,96C 'name':5A,31B,47B,67C,93C 'node':16B 'odbc':17B,25B 'packag':18B 'pass':32B,87C 'postgresql':19B,24B 'privileg':54B,104C 'psqlodbc':1A,20B,22B,61C,110C 'put':27B 'python':21B 'queri':38B,73C 'receiv':69C 'run':6A,49B 'schema':30B,66C,92C 'splice':62C 'sql':8A,51B,101C 'sqlspecialcolumn':2A,34B,59C,95C 'tabl':28B,64C,90C 'untrust':4A,89C 'version':108C 'without':39B,74C","nicknames":[],"mitigations":[],"who_affected":"Applications that use the psqlODBC driver and pass table or schema names to SQLSpecialColumns that an untrusted party can influence. Applications that only use fixed, internal names, or that do not call SQLSpecialColumns, are not exposed to this flaw. The sources do not say whether a specific default configuration is required.","tier":"B","verified":{},"analyst_revisit_at":null,"fix_status":"available","audience":"developers","plain_action":null,"pkeys":[],"ptokens":[],"labels":["c","high","node","odbc","package","postgresql","psqlodbc","python"],"first_public_at":"2026-11-02T19:18:03+00:00","kev":null,"cvss_vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H","cvss_by":"f86ef6dc-4d3a-42ad-8f28-e6d5547a5007","poc_count":0,"sources":[{"source":"nvd","external_id":"CVE-2026-120062","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-120062","severity":null,"published_at":"2026-11-02T19:18:03+00:00","modified_at":"2026-11-02T19:18:03+00:00","first_seen_at":"2026-11-02T19:24:40+00:00","fetched_at":"2026-11-02T19:24:40+00:00","note":null}],"documents":[{"id":53473,"url":"https://github.com/postgresql-interfaces/psqlodbc/security/advisories/GHSA-gg8f-fx3w-rj33","title":"Vendor advisory: github.com","kind":"vendor","source":"nvd","publisher":"vendor","text":null,"published_at":null,"relation":"advisory","confidence":null,"note":"Vendor advisory: github.com"}],"notice":"Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai"}