archive-bomb-scanner icon indicating copy to clipboard operation
archive-bomb-scanner copied to clipboard

False alarm in usdz file

Open joergviola opened this issue 1 year ago • 1 comments

A USDZ-file is a ZIP Archive. I have changed the extension from usdz to zip. I can explode the archive on Mac without any Problems. But the ZIPEngine identified it as bomb, because: "size":12281,"size2":3956 in ZipEngine:55

What am I doing wrong?

2cf3518f-a946-42e3-860f-5c60b8533469_ar_iOS.zip

joergviola avatar Oct 02 '24 09:10 joergviola

I will check this file as soon as possible.

odan avatar Oct 02 '24 13:10 odan

I have checked this file.

The "rule" is that the sum of all files must be the same as the file header uncompressed size at offset 22. See here: https://en.wikipedia.org/wiki/ZIP_(file_format)#File_headers

Results:

Expected value = Sum ZIP index file size:       6890117 bytes / 6.57  MB
Actual value = File header uncompressed size:     12369 bytes / 0.018 MB

So the expected (real size) is not the same as the sum of all files.

image

This means, that the uncompressed size within the ZIP file header (at offset 22) is not correct in this file.

odan avatar Oct 10 '24 12:10 odan

I see - thank you very much for your effort! The file is actually created by a USDZ export from the threejs 3D Library for an Augmented Reality scene. Something must go wrong on their side. Thank you!

joergviola avatar Oct 10 '24 13:10 joergviola