PostgreSQL psqlODBC
psqlODBC SQL injection through SQLSpecialColumns table and schema names
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.
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
- < 18.00.0006
Fixed in 18.00.0006
Mitigation
Upgrade to psqlODBC 18.00.0006 or later. SQLSpecialColumns passes the escaped names to its catalog queries, as the other catalog functions do.
Workaround
Validate table and schema names against the catalog, or reject names containing quote characters or backslashes, before calling SQLSpecialColumns.
References
- Vendor advisory github.com/postgresql-interfaces/psqlodbc/secu…
Timeline
Days relative to CVE publicationNo public PoC found yet; not in CISA KEV.
PoC repositories
Found on GitHub.No PoC repositories found yet.