Read the docs

Integer underflow in JSON::XS incremental parser corrupts buffer length

Priority LOW 22CWE-191Published · Updated

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

EPSS 0.00204 10th percentileScored 2026-11-16
Fix Fixed JSON-XS: 4.05

SSVC decision points

Not available: CISA has not published SSVC decision points for this record.

Affected products

VendorProductAffected versionsFixed inStatusSource
—JSON-XS4.0_00 to before 4.054.05Patch availableCNA
  • 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

  1. 2026-11-14 Threatist record created from CVE-2026-129113
  2. 2026-11-14 Alias added: GHSA-4q52-849c-cv9p

References

Sources