I'm raising this ticket as we're using Apache POI in our product and some customers are generated very big files. Using Apache POI 4.x these files were corrupted and excel had to repair them. With the 5.0 this is no longer an issue. (bug: https://bz.apache.org/bugzilla/show_bug.cgi?id=57342 ) When we're trying to open it back using Apache POI, we get the following error: Caused by: java.io.IOException: Zip bomb detected! The file would exceed the max size of the expanded data in the zip-file. This may indicates that the file is used to inflate memory usage and thus could pose a security risk. You can adjust this limit via ZipSecureFile.setMaxEntrySize() if you need to work with files which are very large. Uncompressed size: 4294969726, Raw/compressed size: 356720128 Limits: MAX_ENTRY_SIZE: 4294967295, Entry: xl/worksheets/sheet1.xml I built a version that allows the setMaxEntrySize to be greater than ~4GB and was able to increase this value to 14GB and open the file without any problem. Would it be possible to increase the limit? https://github.com/apache/poi/blob/trunk/poi-ooxml/src/main/java/org/apache/poi/openxml4j/util/ZipSecureFile.java#L76 Or can we use a different method to open the files?
I've applied a change to remove the 4Gb limit - will be part of POI 5.1.0