Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSend API request with crafted sampleSizes array
-
DeliveryApplication passes attacker-controlled sizes to trainFromBufferDirect
-
ExploitNative JNI code sums lengths without calling GetDirectBufferCapacity
-
ExecutionOut-of-bounds read walks past DirectBuffer allocation
-
ImpactJVM process terminates (denial of service)
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 calls Zstd.trainFromBufferDirect (or the underlying native trainFromBufferDirect0) with a sampleSizes array that is fully or partially controlled by the attacker. Dictionary training is not part of normal compression or decompression workflows; it is a specialized API used to build custom Zstd dictionaries from representative data samples. Applications that do not expose this code path to untrusted callers - which is the majority of zstd-jni consumers - are not exploitable. If the calling application enforces authentication before reaching the dictionary-training endpoint, the effective privilege requirement is elevated to match that gate. Exploitation is therefore limited to deployments where: (1) zstd-jni 1.3.3-1 through 1.5.7-13 is in use, and (2) the application accepts attacker-controlled per-sample size values in calls to the dictionary-training API without independent bounds validation. |
| Impact | The CVSS 4.0 score of 8.7 (AV:N/AC:L/AT:N/PR:N/UI:N/VA:H) reflects the severity of a remotely triggerable JVM crash with no authentication barrier. Real-world exploitability is constrained by the attack surface: Zstd.trainFromBufferDirect is a dictionary-training API, not invoked during routine compression or decompression, so only applications that explicitly expose this code path to untrusted input are vulnerable. EPSS data was not provided in the intelligence package, making probability-of-exploitation comparisons unavailable; however, the absence of a CISA KEV listing and no identified public exploit suggest exploitation remains theoretical. The SSVC automatable dimension is uncertain - while the CVSS vector implies no barriers to automation, reaching a dictionary-training endpoint requires a specific application architecture that is far from universal. The JVM-crash impact would be immediately disruptive to any service running in the affected process, including high-throughput streaming pipelines built on Apache Kafka or Spark where zstd-jni is a common dependency - even a mid-sized data engineering team should treat this as a straightforward patch-and-deploy rather than a triage-and-defer item. CVSS 4.0 accurately characterizes availability-only impact (VA:H, VC:N/VI:N), correctly ruling out information disclosure as a practical outcome since the OOB read triggers a crash rather than exfiltrating buffer contents. |
| Exploit ScenarioDerived | An attacker targeting a service that exposes Zstd dictionary training - for example, a data compression API that allows users to submit sample corpora - sends a request containing a sampleSizes array whose values sum to more than the capacity of the accompanying ByteBuffer. The native JNI layer iterates over the oversized lengths without a bounds check, reading past the DirectBuffer allocation, which triggers a JVM hard crash and takes down the entire service process. No public proof-of-concept exploit has been identified at time of analysis, but the fix commit provides sufficient detail to reconstruct the vulnerable code path. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Sep 09, 2026
Out-of-bounds memory access in zstd-jni versions 1.3.3-1 through 1.5.7-13 enables unauthenticated network-accessible attackers to crash the JVM by supplying crafted sample-size arrays to the Zstd.trainFromBufferDirect dictionary-training API. The native C implementation (jni_zdict.c) failed to sum caller-supplied sample lengths against the DirectBuffer's actual capacity before iterating, allowing the native code to walk past the buffer allocation boundary and trigger a hard JVM termination. A patched release (v1.5.7-14) is available; no public exploit has been identified at time of analysis.
RemediationAI
Upgrade zstd-jni to version 1.5.7-14 or later; the patched release is available at https://github.com/luben/zstd-jni/releases/tag/v1.5.7-14 and is documented in security advisory GHSA-257p-3h6w-pg7h. Maven and Gradle consumers should update their dependency declaration to com.github.luben:zstd-jni:1.5.7-14. If an immediate dependency upgrade cannot be coordinated (e.g., due to transitive dependency constraints in a managed build), the effective workaround is to disable or gate any application-level endpoints that invoke Zstd.trainFromBufferDirect or trainFromBufferDirect0 with caller-controlled sample size arrays; this eliminates the attack surface entirely at the cost of disabling dictionary-training functionality. Input validation at the application layer (rejecting sample size arrays whose sum exceeds a known buffer bound before the JNI call) can also prevent exploitation but is fragile and not a substitute for patching.
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 JNI wrapper that exposes Facebook's Zstandard compression algorithm to the JVM. The vulnerability resides in jni_zdict.c, specifically the Java_com_github_luben_zstd_Zstd_trainFromBufferDirect0 native function, which accepts a Java DirectBuffer containing training samples and a long[] array of per-sample byte lengths. Prior to the fix, the code iterated over the sample-size array and passed the total to the ZDICT_trainFromBuffer API without first calling GetDirectBufferCapacity to obtain the buffer's actual allocation size. CWE-125 (Out-of-Bounds Read) is the root cause: the native pointer advances past the end of the allocated buffer region during size summation and ZDICT processing, triggering undefined behavior in the JVM process that manifests as an unrecoverable crash rather than a catchable Java exception. The fix (commits bba6cfca and 53d3c634) adds a GetDirectBufferCapacity call and a pre-loop validation that aborts to an error handler if any sample size is negative or the sum exceeds buffer capacity.
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:N/VI:N/VA:H/SC:N/SI:N/SA:N
OOB read causes JVM crash (A:H) with no confidentiality or integrity impact; network-reachable without auth via exposed dictionary-training API.
AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
DescriptionCVE.org
zstd-jni before 1.5.7-14 fails to validate the samples buffer capacity in Zstd.trainFromBufferDirect, allowing attackers to read past buffer boundaries by supplying oversized per-sample lengths. Attackers can trigger out-of-bounds memory access by providing crafted sample length arrays that cause the native implementation to walk past the buffer allocation, resulting in JVM termination.
Technical POC Analysis
An unchecked out-of-bounds read (CWE-125) in the native dictionary-training path of zstd-jni.
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 integrated into data processing and streaming applications, contains a remote denial-of-service vulnerability allowing unauthenticated attackers to crash the Java Virtual Machine by sending specially crafted data. Organizations using this library face potential service outages without any user authentication requirement.
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.
Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.
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 allows attackers who can supply dictionary constructor pa
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
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-75022
GHSA-v36p-vv44-8qfg
NVD
CVE.org
EPSS
VulDB
Exploit-DB