commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <>
Subject Re: [compress] Getting external attributes from a ZipArchiveEntry
Date Thu, 11 Jun 2015 04:29:03 GMT
On 2015-06-10, Kristina Chodorow wrote:

> ZipArchiveEntry.getExternalAttributes() is always returning 0 for me.  I
> have pasted a hex dump of the zip file I'm testing with at the bottom of
> email: 2 files of 0 bytes, one named x and one named y.  Both of their
> external attributes are 33184 (a081 in the hex dump).  However, running the
> following program gives me 0 for both of their external attributes:

External attributes are stored inside the central directory which is at
the end of the archive.  When using ZipArchiveInputStream the central
directory is only ever reached once all entries have been read.

If you need to access the information from the central directory you
should use ZipFile rather than ZipArchiveInputStream.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message