CVE-2025-1735
pgsql extension does not check for errors during escaping
Publication Date | 2025-07-05 |
---|---|
Severity | Critical |
Type | Cross-Site Request Forgery |
Affected PHP Versions |
|
Fixed Product Versions |
|
CVE Details
A missing error check in the pgsql extension's escaping functionality could result in SQL injection, and missing error handling could lead to crashes due to null pointer dereferences.
Recommendations
If you use Postgres within your PHP application, and rely on it for escaping/quoting SQL, you should update to a version of PHP that corrects the issue immediately.
Also note that this fix is dependent on updated PostegreSQL client libraries on the system hosting PHP. Older Linux versions (such as RHEL 7.x, CentOS 7, Debian 10, Ubuntu 18.04) do not include this driver fix in the default operating system installation. Related to PostgreSQL CVE-2025-1094 (Versions before PostgreSQL 17.3, 16.7, 15.11, 14.16, and 13.19 are affected).