Snyk has a proof-of-concept or detailed explanation of how to exploit this vulnerability.
The probability is the direct output of the EPSS model, and conveys an overall sense of the threat of exploitation in the wild. The percentile measures the EPSS probability relative to all known EPSS scores. Note: This data is updated daily, relying on the latest available EPSS model version. Check out the EPSS documentation for more details.
In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.
Test your applicationsUpgrade org.xerial.snappy:snappy-java
to version 1.1.10.1 or higher.
Affected versions of this package are vulnerable to Integer Overflow or Wraparound via the function compress(char[] input)
in Snappy.java
due to improper validation of the array length.
Exploiting this vulnerability is possible when the “buf” array compiled by the maxCompressedLength
function is successfully allocated but its size might be too small to use for the compression, causing a fatal Access Violation error.
Note: The issue most likely won’t occur when using a byte array since creating a byte array of size 0x80000000 (or any other negative value) is impossible in the first place.
package org.example;
import org.xerial.snappy.Snappy;
import java.io.*;
public class Main {
public static void main(String[] args) throws IOException {
char[] uncompressed = new char[0x40000000];
byte[] compressed = Snappy.compress(uncompressed);
}
}