CVE-2026-78183: CWE-787 Out-of-bounds Write
Description
CVE-2026-78183 is a critical heap out-of-bounds write vulnerability in DBD::Pg version 3.21.0 for Perl. The flaw occurs in the quote_float function, which incorrectly allocates insufficient memory for certain special floating-point literals such as NaN, Inf, and Infinity, causing a buffer overflow by 2 bytes. This vulnerability was introduced in version 3.21.0 due to a rewrite of quote.c. It can be triggered via the $dbh->quote method when quoting these special literals as numeric values.
CVSS v3.1
Score 9.8critical
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
DBD::Pg 3.21.0 for Perl contains a heap out-of-bounds write in the quote_float function. The function allocates memory based on the length of the string plus one byte for the NULL terminator, which is correct for normal numeric values. However, for special literals like NaN, Inf, +Inf, -Inf, Infinity, +Infinity, and -Infinity, the function emits the literal surrounded by quotes plus a NULL terminator, requiring length plus three bytes. This mismatch causes a 2-byte overflow (one quote and one NULL) on the heap. The vulnerability can be exploited by calling $dbh->quote with these special literals and the DBI::SQL_NUMERIC type. This regression was introduced in version 3.21.0 during a rewrite of quote.c.
Potential Impact
Successful exploitation of this vulnerability can lead to heap corruption, which may result in arbitrary code execution, denial of service, or data corruption. The CVSS score of 9.8 reflects the critical nature of this flaw with high impact on confidentiality, integrity, and availability. No known exploits in the wild have been reported at this time.
Mitigation Recommendations
No official patch or remediation is currently available for this vulnerability. Users should avoid using DBD::Pg version 3.21.0, especially the quote_float function with special floating-point literals, until a fix is released. Monitor the vendor or CPAN security advisories for updates and apply official patches once available.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- CPANSec
- Date Reserved
- 2026-08-23T16:38:31.813Z
- State
- PUBLISHED
Threat ID: 6a8b5310acd9273b4954fa2c
Added to database: 08/23/2026, 20:07:44 UTC
Last enriched: 09/10/2026, 12:52:26 UTC
Last updated: 10/06/2026, 18:48:25 UTC
Views: 81
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.