CVE Index中文
L3 · ShartedPerl · JSON · CPAN · memory safetyperl-json-xs

Perl JSON::XS discloses seven parsing and serialization flaws

CPANSec disclosed seven JSON::XS vulnerabilities fixed in 4.05. Malformed JSON can exhaust memory or the stack, and specific incremental parsing and tagged serialization paths can mishandle memory. Update services that parse or encode untrusted data.

Disclosed
Nov 13, 2026
Public disclosure date
Severity
Sharted
7 CVEs tracked here
Splash zone
Perl applications using JSON::XS before 4.05. Exposure varies with incremental parsing, malformed input, and tagged values.
perl
In the wild
Unknown

What happened

The input paths differ by flaw. Several affect the incremental decoder, and others affect invalid object or string parsing. The stack exhaustion and released-memory read depend on tagged mode. The latter is an encoding issue involving a FREEZE result. Services parsing untrusted JSON are the main priority, along with apps using tagged serialization.

CPANSec identifies memory exhaustion, hangs, crashes and invalid memory accesses as concerns. Its report does not establish exploitation in production. Request limits and disabling optional features reduce exposure while you prepare the upgrade.

What’s in the bowl

Incremental parser can exceed max_size

Before 4.05, a NUL byte can cause incr_parse to accumulate incremental input beyond the configured size limit.

Memory leak on a missing object colon

Before 4.05, rejecting an object with a missing colon can leave the allocation for a decoded key unreleased.

Tagged data can exhaust the stack

Before 4.05, decoding deeply nested tagged values with allow_tags enabled can exhaust the stack.

Memory leak on a malformed long string

Before 4.05, rejection of a malformed long string can leave memory allocated for the already-decoded portion.

Incremental skip corrupts the buffer length

From 4.0_00 to before 4.05, after a malformed top-level number, incr_skip can use a stale offset beyond the end of the buffer and underflow its length.

One-byte heap write past the buffer

From 3.04 to before 4.05, appending a one-byte chunk during incremental parsing can write one byte beyond the heap buffer.

Tagged serialization reads released stack memory

From 3.0 to before 4.05, under allow_tags, serializing a FREEZE method result that grows the Perl stack can read released stack memory.

Fixed versions

ProductSafe fromNote
JSON::XS4.05First upstream release fixing the seven issues

Crime-scene timeline

  1. Nov 13, 2026

    JSON-XS 4.05 is released

    The distribution changelog describes the parser and serialization fixes.

  2. Nov 14, 12:05 UTC

    CPANSec publishes seven vulnerability advisories

    The oss-security post gives affected ranges, trigger conditions and remediation.

Who said what

We list each claim and who made it. Primary sources (the vendor, the researcher, the registry) are marked. Where reports disagree, we grade by the worst credible case.