snappy-java: Heap buffer overflow in Snappy.uncompress*Array typed-array methods
Published 27 Oct 2026 · Updated 27 Oct 2026
Is your project on an affected org.xerial.snappy:snappy-java?
Look after several Java apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie
Affected package
- Affected
- <1.1.10.9
- Fixed in
- 1.1.10.9
mvn versions:use-dep-version -Dincludes=org.xerial.snappy:snappy-java -DdepVersion=1.1.10.9 -DforceVersion=trueDetails
Impact
Snappy.uncompressCharArray, uncompressShortArray, uncompressIntArray, uncompressLongArray, uncompressFloatArray and uncompressDoubleArray sized the result array by dividing the declared uncompressed byte length by the element size, but native code wrote the full byte length. If the declared length is not a multiple of the element size, up to 7 bytes are written past the end of the Java array, corrupting the heap.
Patches
Fixed in 1.1.10.9 (#739). These methods now reject uncompressed lengths that are not a multiple of the element size with SnappyIOException.
Workarounds
Check that Snappy.uncompressedLength(input) is a multiple of the element size before calling these methods.
Is GHSA-gwq9-9ffj-mvrv in any of your client repos?
Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected org.xerial.snappy:snappy-java, and gives you the command that fixes it.
More advisories for org.xerial.snappy:snappy-java
- MediumCVE-2026-116590snappy-java: JVM crash from unchecked ranges in Snappy.arrayCopy and SnappyOutputStream.rawWrite · 27 Oct 2026
- HighCVE-2026-108106snappy-java: Unbounded memory allocation from attacker-declared uncompressed lengtha · 27 Oct 2026
- HighCVE-2023-43642snappy-java's missing upper bound check on chunk length can lead to Denial of Service (DoS) impact · 25 Sept 2023
- HighCVE-2023-34455snappy-java's unchecked chunk length leads to DoS · 15 Jun 2023
- MediumCVE-2023-34454snappy-java's Integer Overflow vulnerability in compress leads to DoS · 15 Jun 2023
- MediumCVE-2023-34453snappy-java's Integer Overflow vulnerability in shuffle leads to DoS · 15 Jun 2023
References
- Linkgithub.com/xerial/snappy-java/security/advisories/GHSA-gwq9-9ffj-mvrv
- Advisorynvd.nist.gov/vuln/detail/CVE-2026-93451
- Linkgithub.com/xerial/snappy-java/issues/729
- Linkgithub.com/xerial/snappy-java/pull/739
- Linkgithub.com/xerial/snappy-java/commit/943c6043a292568575e8347af4507d015e802c75
- Packagegithub.com/xerial/snappy-java
- Linkgithub.com/xerial/snappy-java/blob/v1.1.10.8/src/main/java/org/xerial/snappy/Snappy.java#L802
- Linkgithub.com/xerial/snappy-java/releases/tag/v1.1.10.9
- Linkwww.vulncheck.com/advisories/snappy-java-through-1.1.10.8-buffer-overflow-via-typed-uncompress-methods
Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.