Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessIdentify application endpoint accepting custom compression dictionary parameters
-
DeliveryCraft request with negative offset or oversized length value
-
ExploitApplication passes unchecked values to ZstdDictCompress JNI constructor
-
ExecutionNative jni_fast_zstd.c reads beyond allocated byte array into native heap
-
ImpactJVM crash causes service DoS or native heap bytes surface in dictionary context
Vulnerability Assessment
| Weakness |
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, read limits
MITRE ATT&CK
1 technique across 1 tactic: Collection The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires that the target application passes attacker-controlled offset or length integer values to the ZstdDictCompress(byte[], int, int, int) or ZstdDictDecompress(byte[], int, int) constructors. This condition is satisfied only when the application accepts a custom compression dictionary from untrusted external input and derives the slice parameters (offset, length) from that same untrusted source rather than from internal constants. Applications using ZstdDictCompress with statically defined, internally computed dictionary slices are not exploitable regardless of network exposure. The CVSS PR:N assumption holds only in applications where no authentication is required before the user-controlled parameters reach this code path; many production deployments that use custom dictionaries will require at least user-level authentication, which would reduce the effective PR from N to L. What limits exploitation further is the indirect nature of the attack path: the attacker cannot reach the JNI constructor directly and must traverse the application's own API to do so. |
| Impact | The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:H) scores 8.8, modelling a scenario where attacker-supplied offset/length parameters reach the constructor over a network path without authentication. The primary real-world impact is high availability: a crafted parameter pair reliably crashes the JVM, making this an effective DoS primitive for any application that exposes this code path to untrusted input. The limited confidentiality component (VC:L) reflects that native heap bytes can be redirected into the compression dictionary context, but useful data recovery is constrained by ASLR and heap layout uncertainty. Critically, this is not a direct network-to-JNI attack - exploitation requires that the application itself forward attacker-controlled offset/length values to ZstdDictCompress, making the AV:N/PR:N rating application-context-dependent rather than universal. Applications in data pipeline roles (Kafka broker plugins, Spark custom compressors) that accept user-supplied dictionaries represent the highest real-world risk tier. Applications using static, internally-defined dictionaries are not exploitable. No CISA KEV listing and no public POC have been identified at time of analysis; EPSS data was not provided. |
| Exploit ScenarioDerived | An attacker targeting a data ingestion service that accepts custom Zstandard compression dictionaries submits an API request with a crafted negative offset or an offset+length sum exceeding the dictionary buffer size. The application passes these values unchecked to ZstdDictCompress, the JNI layer forwards them to native code, and the C runtime performs an out-of-bounds read on the heap - causing an immediate JVM crash and service outage. No public POC has been identified, but the fix code makes reproduction straightforward for any developer familiar with the JNI interface. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Sep 09, 2026
Out-of-bounds read in zstd-jni versions 1.2.0 through 1.5.7-13 allows attackers who can supply dictionary constructor parameters to crash the JVM and potentially read limited native heap memory. The ZstdDictCompress constructor passed unvalidated offset and length values directly to the C JNI layer, where out-of-range values cause the native code to read beyond the allocated Java heap array. No CISA KEV listing or public exploit has been identified; the CVSS 4.0 score of 8.8 reflects high availability impact via reliable JVM crash and limited confidentiality exposure from native heap reads.
RemediationAI
Upgrade zstd-jni to version 1.5.7-14 or later, available at https://github.com/luben/zstd-jni/releases/tag/v1.5.7-14. The fix was applied across two commits: 0d64de4dee6606ff506be36c7f2e714ad0c80fdb (adds the primary ZstdDictCompress bounds check and corrects the inverted ZstdDictDecompress guard) and 1c4e5a6c3ce8458095225d987d669e6a0937734a (additional hardening). The security advisory is at https://github.com/luben/zstd-jni/security/advisories/GHSA-ff36-7w3w-g8rm. For deployments that cannot immediately upgrade, add caller-side validation before invoking ZstdDictCompress: enforce offset >= 0, length >= 0, and offset + length <= dict.length in the application layer. As a defence-in-depth measure, if dictionary parameters originate from external input, reject requests whose offset or length values are not within known-valid ranges before they reach the JNI layer.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
zstd-jni (CPE: cpe:2.3:a:luben:zstd-jni:*:*:*:*:*:*:*:*) is a Java Native Interface wrapper for Facebook's Zstandard compression algorithm, widely embedded in Apache Kafka, Spark, Hadoop, and Flink. The affected code path is ZstdDictCompress(byte[] dict, int offset, int length, int level): before v1.5.7-14, no bounds validation was performed on offset or length in Java before dispatch to the native jni_fast_zstd.c layer. CWE-125 (Out-of-Bounds Read) applies - a negative offset or an offset+length sum exceeding dict.length causes the C runtime to read beyond the allocated byte array into adjacent native heap memory. The companion ZstdDictDecompress class contained an analogous but inverted guard (offset > dict.length - length instead of the correct length > dict.length - offset), creating a second exploitable path through the same primitive. The patch in commit 0d64de4 adds the guard: if (offset < 0 || length < 0 || length > dict.length - offset) throw IllegalArgumentException, and corrects the inverted check in ZstdDictDecompress.
Know when Zstd Jni gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:H/SC:N/SI:N/SA:N
Network-reachable via applications forwarding untrusted parameters; no auth required at library boundary; JVM crash yields high availability impact; limited native heap read yields low confidentiality impact.
AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:H
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
DescriptionCVE.org
zstd-jni versions before 1.5.7-14 fail to validate offset and length parameters in the ZstdDictCompress constructor, allowing out-of-bounds memory reads. Attackers can supply untrusted offset or length values to read native heap memory into the compression dictionary, typically causing JVM crashes.
Technical POC Analysis
The defect is in com.github.luben.zstd.ZstdDictCompress in the constructor ZstdDictCompress(byte[] dict, int offset, int length, int level).
Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.
Executive ViewAI
zstd-jni, a Java compression library, contains a flaw in versions 1.2.0-1.5.7-13 allowing attackers to crash applications and read sensitive data from system memory. With no public exploit identified at time of analysis, organizations nonetheless face material risks to service availability and data confidentiality. Patches are available.
Apply vendor patch.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.
Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.
Use-after-free in zstd-jni's Dictionary Sharing component allows remote attackers to corrupt native heap memory through
Out-of-bounds read in zstd-jni versions 1.2.0 through 1.5.7-13 exposes JVM-based applications to service termination and
Out-of-bounds read in zstd-jni versions 1.5.5-6 through 1.5.7-13 exposes JVM-based applications to memory disclosure or
Out-of-bounds memory reads in zstd-jni versions 1.1.1 through 1.5.7-13 allow unauthenticated remote attackers to crash t
Out-of-bounds memory access in zstd-jni versions 1.3.3-1 through 1.5.7-13 enables unauthenticated network-accessible att
Use-after-free in zstd-jni versions 1.3.8-4 through 1.5.7-13 allows attackers to trigger silent data corruption or JVM c
Use-after-free in zstd-jni versions 1.3.8-4 through 1.5.7-13 allows callers to invoke setDict, setLongMax, setLevel, and
Infinite-loop denial of service in zstd-jni versions 1.4.8-4 through 1.5.7-13 allows thread starvation by passing negati
EUVD-2026-74791
GHSA-vc57-7frc-7vqx
NVD
CVE.org
EPSS
VulDB
Exploit-DB