[File] Identifying Microsoft XPS (XML Paper Specification) / Improve .zip container detection
Christos Zoulas
christos at zoulas.com
Sun May 17 13:33:47 EDT 2026
Yup, adding code to list the zip directory would be helpful!
christos
> On May 15, 2026, at 4:20 PM, Christoph Biedl <astron.com.bwoj at manchmal.in-ulm.de> wrote:
>
> Debian bug report: https://bugs.debian.org/1134126
> This also has links to test samples.
>
> Long story short, this is yet another file format using .zip as
> a container. Sometime the ooxml detection hits for "[Content_Types].xml"
> being the first item - it the order is different, file(1) falls back to
> "Zip archive data".
>
> Now I cannot see how to handle this with plain magic in a robust way but
> perhaps somebody else has ideas.
>
> Otherwise this makes me think - possibly not for the first time - file
> should eventually become able to use the file listing of a .zip file for
> identification - parsing in the binary data like in magic/Magdir/msooxml
> looks scary and is fairly fragile.
>
> Christoph
>
> --
> File mailing list
> File at astron.com
> https://mailman.astron.com/mailman/listinfo/file
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 235 bytes
Desc: Message signed with OpenPGP
URL: <http://mailman.astron.com/pipermail/file/attachments/20260517/c5690f7d/attachment.asc>
More information about the File
mailing list