Heap-based buffer overflow in PostgreSQL - CVE-2005-0245

 

Heap-based buffer overflow in PostgreSQL - CVE-2005-0245

Published: June 21, 2025


Vulnerability identifier: #VU111739
CSH Severity: Medium
CVSS v4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N]
CVE-ID: CVE-2005-0245
CWE-ID: CWE-122
Exploitation vector: Remote access
Exploit availability: Public exploit is available

Vulnerability details

The vulnerability allows a remote user to execute arbitrary code on the target system.

The vulnerability exists due to a boundary error. A remote user can pass a large number of arguments to a refcursor function (gram.y), trigger a heap-based buffer overflow and execute arbitrary code on the target system.

Successful exploitation of this vulnerability may result in complete compromise of vulnerable system.


Affected software

PostgreSQL

How to mitigate CVE-2005-0245

Install updates from vendor's website.

PostgreSQL - addressed in versions 7.2.7, 7.3.9, 7.4.7, 8.0.1

Links to Public Exploits and PoC-codes

External References

Related Security Bulletins