项目场景:
提示:这里简述项目相关背景:
This may indicate that the file is used to inflate memory usage and thus could pose a security risk.
You can adjust this limit via ZipSecureFile.setMinInflateRatio() if you need to work with files which exceed this limit.
Uncompressed size: 741169, Raw/compressed size: 7411, ratio: 0.009999
问题描述
提示:这里描述项目中遇到的问题:
Using apache poi - Zip Bomb detected
原因分析:
提示:这里填写问题的分析:
主要原因是文件太大,解决办法增加如下代码
解决方案:
提示:这里填写该问题的具体解决方案:
// ZipSecureFile.setMinInflateRatio(-1.0d);
ZipSecureFile.setMinInflateRatio(0.001);