Security Vulnerability Report
中文
CVE-2024-14031 CVSS 8.1 HIGH

CVE-2024-14031

Published: 2026-03-31 12:16:26
Last Modified: 2026-04-13 12:53:13
Source: 9b29abf9-4ab0-4765-b253-1875cd9b441e

Description

Sereal::Encoder versions from 4.000 through 4.009_002 for Perl embeds a vulnerable version of the Zstandard library. Sereal::Encoder embeds a version of the Zstandard (zstd) library that is vulnerable to CVE-2019-11922. This is a race condition in the one-pass compression functions of Zstandard prior to version 1.3.8 could allow an attacker to write bytes out of bounds if an output buffer smaller than the recommended size was used.

CVSS Details

CVSS Score
8.1
Severity
HIGH
CVSS Vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

Configurations (Affected Products)

cpe:2.3:a:yves:sereal\:\:encoder:*:*:*:*:*:perl:*:* - VULNERABLE
Sereal::Encoder 4.000 - 4.009_002

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
#!/usr/bin/perl use strict; use warnings; # This PoC demonstrates the usage of Sereal::Encoder. # Exploitation requires a version between 4.000 and 4.009_002. # The underlying zstd race condition can be triggered by compressing data # that forces the encoder into a state where output buffer management fails. use Sereal::Encoder qw(encode_sereal); my $data = "A" x 10000; # Large payload to stress buffer allocation my $encoder = Sereal::Encoder->new({ }); print "Attempting to encode data...\n"; eval { my $encoded = $encoder->encode($data); print "Encoding successful (might not be vulnerable or patched).\n"; }; if ($@) { print "Error occurred (possible crash or vulnerability trigger): $@\n"; }

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2024-14031", "sourceIdentifier": "9b29abf9-4ab0-4765-b253-1875cd9b441e", "published": "2026-03-31T12:16:26.310", "lastModified": "2026-04-13T12:53:12.687", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "Sereal::Encoder versions from 4.000 through 4.009_002 for Perl embeds a vulnerable version of the Zstandard library.\n\nSereal::Encoder embeds a version of the Zstandard (zstd) library that is vulnerable to CVE-2019-11922. This is a race condition in the one-pass compression functions of Zstandard prior to version 1.3.8 could allow an attacker to write bytes out of bounds if an output buffer smaller than the recommended size was used."}], "metrics": {"cvssMetricV31": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H", "baseScore": 8.1, "baseSeverity": "HIGH", "attackVector": "NETWORK", "attackComplexity": "HIGH", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "HIGH"}, "exploitabilityScore": 2.2, "impactScore": 5.9}]}, "weaknesses": [{"source": "[email protected]", "type": "Primary", "description": [{"lang": "en", "value": "CWE-787"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:yves:sereal\\:\\:encoder:*:*:*:*:*:perl:*:*", "versionStartIncluding": "4.000", "versionEndExcluding": "4.010", "matchCriteriaId": "FFD60C5E-CBFB-4CA6-B28F-B3E80D5F7F13"}]}]}], "references": [{"url": "https://github.com/advisories/GHSA-w77f-wv46-4vcx", "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e", "tags": ["Not Applicable"]}, {"url": "https://metacpan.org/release/YVES/Sereal-Encoder-4.010/changes", "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e", "tags": ["Release Notes"]}, {"url": "https://www.cve.org/CVERecord?id=CVE-2019-11922", "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e", "tags": ["Not Applicable"]}]}}