CVE-2025-12818: PostgreSQL libpq undersizes allocations, via integer wraparound
Integer wraparound in multiple PostgreSQL libpq client library functions allows an application input provider or network peer to cause libpq to undersize an allocation and write out-of-bounds by hundreds of megabytes. This results in a segmentation fault for the application using libpq. Versions before PostgreSQL 18.1, 17.7, 16.11, 15.15, 14.20, and 13.23 are affected.
Other sources
PostgreSQL libpq undersizes allocations, via integer wraparound
— Microsoft
Affected Software
Event History
Frequently Asked Questions
What is the severity of CVE-2025-12818?
CVE-2025-12818 is categorized as a high severity vulnerability due to its potential to cause segmentation faults and exploit memory management issues.
How do I fix CVE-2025-12818?
To fix CVE-2025-12818, upgrade your PostgreSQL libpq library to versions 18.2, 17.8, 16.12, 15.16, 14.21, or 13.24 or later.
What is affected by CVE-2025-12818?
The vulnerability affects multiple versions of the PostgreSQL libpq client library prior to the patched versions.
What type of vulnerability is CVE-2025-12818?
CVE-2025-12818 is an integer wraparound vulnerability that can lead to out-of-bounds memory allocation.
What impact does CVE-2025-12818 have on applications?
CVE-2025-12818 can cause applications using the libpq library to crash due to segmentation faults from improper memory allocation.