Integer underflow in JSON::XS incremental parser corrupts buffer length
Key facts
- Attack vector
- —
- Privileges required
- —
- User interaction
- —
- Attack complexity
- —
- Impact type
- —
- Confidentiality · integrity · availability
- —
- Fix status
- Fixed
No CVSS vector from any source. Fix status from CNA.
Summary
JSON::XS versions from 4.0_00 before 4.05 for Perl corrupt the incremental buffer length after a top-level number, because the parser keeps an offset into bytes it has already consumed. A later incr_parse call without new input moves that offset past the end of the buffer, and incr_skip then wraps the buffer length through an integer underflow (CWE-191). A peer that sends input such as "1-2" to an incr_parse consumer can make the next read of incr_text terminate the process through perl's uncatchable out-of-memory path.
Written with Claude Haiku 5.5 from the sources below · 2026-11-14
Description from the CNA
JSON::XS versions from 4.0_00 before 4.05 for Perl corrupt the incremental buffer length by chopping past its end in incr_skip after a top-level number. The incremental parser scans any run of digits, signs, dots and exponent markers as one number, but the decoder stops at the end of a valid number, so the parser keeps an offset into bytes it has not decoded. It then empties the buffer without clearing those bytes, and a later incr_parse call without new input reads them again and moves the offset past the end of the buffer. incr_skip, the documented recovery after an error, removes that many bytes and the buffer length wraps. A peer sending input such as "1-2" to an incr_parse consumer can make the next read of incr_text exit the process through perl's uncatchable out-of-memory path.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| — | JSON-XS | 4.0_00 to before 4.05 | 4.05 | Patch available | CNA |
- JSON-XS Vendor— Affected 4.0_00 to before 4.05 Fixed in 4.05 Patch available CNA
Remediation
Upgrade JSON::XS to version 4.05 or later, which fixes the flaw.
Written with Claude Haiku 5.5 from the sources below · 2026-11-14
- Fix · CNA JSON-XS Fixed in 4.05
Timeline
- 2026-11-14 Threatist record created from CVE-2026-129113
- 2026-11-14 Alias added: GHSA-4q52-849c-cv9p
References
Sources
- CVE-2026-129113 · CVE Program
- CVE-2026-129113 · NVD
- FIRST EPSS
- GHSA-4q52-849c-cv9p · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences