Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
ZIP (file format)
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== ZIP64 === The original {{mono|.ZIP}} format had a 4 GB (2<sup>32</sup> bytes) limit on various things (uncompressed size of a file, compressed size of a file, and total size of the archive), as well as a limit of 65,535 (2<sup>16</sup>-1) entries in a ZIP archive. In version 4.5 of the specification (which is not the same as v4.5 of any particular tool), PKWARE introduced the "ZIP64" format extensions to get around these limitations, increasing the limits to 16 [[Exabyte|EB]] (2<sup>64</sup> bytes). In essence, it uses a "normal" central directory entry for a file, followed by an optional "zip64" directory entry, which has the larger fields.<ref>{{cite web|url=https://pkware.cachefly.net/webdocs/casestudies/APPNOTE.TXT|format=TXT|title=File : APPNOTE.TXT - .ZIP File Format Specification : Version: 6.3.4|website=Pkware.cachefly.net|access-date=2017-09-09}}</ref> The format of the Local file header (LOC) and Central directory file header (CDFH) are the same in ZIP and ZIP64. However, ZIP64 specifies an extra field that may be added to those records at the discretion of the compressor, whose purpose is to store values that do not fit in the classic LOC or CDFH records. To signal that the actual values are stored in ZIP64 extra fields, they are set to 0xFFFF or 0xFFFFFFFF in the corresponding LOC or CDFH record. If one entry does not fit into the classic LOC or CDFH record, only that entry is required to be moved into a ZIP64 extra field. The other entries may stay in the classic record. Therefore, not all entries shown in the following table might be stored in a ZIP64 extra field. However, if they appear, their order must be as shown in the table. {|class="wikitable" |+ Zip64 extended information extra field |- ! Offset !! Bytes !! Description<ref name="appnote"/> |- | 0 || 2 || Header ID 0x0001 |- | 2 || 2 || Size of the extra field chunk (8, 16, 24 or 28) |- | 4 || 8 || Original uncompressed file size |- | 12 || 8 || Size of compressed data |- | 20 || 8 || Offset of local header record |- | 28 || 4 || Number of the disk on which this file starts |} On the other hand, the format of EOCD for ZIP64 is slightly different from the normal ZIP version.<ref name="appnote"/> {|class="wikitable" |+ Zip64 End of central directory record (EOCD64) |- ! Offset !! Bytes !! Description<ref name="appnote"/> |- | 0 || 4 || End of central directory signature = 0x06064b50 |- | 4 || 8 || Size of the EOCD64 minus 12 |- | 12 || 2 || Version made by |- | 14 || 2 || Version needed to extract (minimum) |- | 16 || 4 || Number of this disk |- | 20 || 4 || Disk where central directory starts |- | 24 || 8 || Number of central directory records on this disk |- | 32 || 8 || Total number of central directory records |- | 40 || 8 || Size of central directory (bytes) |- | 48 || 8 || Offset of start of central directory, relative to start of archive |- | 56 || ''n'' || Comment (up to the size of EOCD64) |} It is also not necessarily the last record in the file. An End of Central Directory Locator follows (an additional 20 bytes at the end). The File Explorer in Windows XP does not support ZIP64, but the Explorer in Windows Vista and later do.{{citation needed|date=October 2015}} Likewise, some extension libraries support ZIP64, such as DotNetZip, QuaZIP<ref>{{cite web | url=http://sourceforge.net/p/quazip/code/HEAD/tree/tags/0.6/quazip/NEWS.txt | title=QuaZIP changes | access-date=2014-01-25 | date=22 January 2014 }}</ref> and IO::Compress::Zip in Perl. [[Python (programming language)|Python]]'s built-in zipfile supports it since 2.5 and defaults to it since 3.4.<ref>{{cite web | url=http://bugs.python.org/issue17201 | title=Python enhancement: Use allowZip64=True by default (3.4) | access-date=2014-05-06}}</ref> [[OpenJDK]]'s built-in java.util.zip supports ZIP64 from version [[Java Dolphin|Java 7]].<ref>{{cite web | url=https://blogs.oracle.com/xuemingshen/entry/zip64_support_for_4g_zipfile | title=ZIP64, The Format for > 4G Zipfile, Is Now Supported | access-date=27 Sep 2010 | last=Shen | first=Xueming | date=17 April 2009 | work=Xueming Shen's Blog | publisher=[[Sun Microsystems]] }}{{Dead link|date=March 2025 |bot=InternetArchiveBot |fix-attempted=yes }}</ref> [[Android (operating system)|Android]] Java API support ZIP64 since Android 6.0.<ref>{{cite web|url=https://code.google.com/p/android/issues/detail?id=68666|title=Sign in - Google Accounts|website=code.google.com|access-date=9 September 2017}}</ref> Mac OS Sierra's Archive Utility notably does not support ZIP64, and can create corrupt archives when ZIP64 would be required.<ref>{{cite web|url=https://github.com/thejoshwolfe/yauzl/issues/69#issuecomment-359188643|title=Error: invalid central directory file header signature when unzipping big files, zipped by mac os Β· Issue #69 Β· thejoshwolfe/yauzl|website=GitHub}}</ref> However, the ditto command shipped with Mac OS will unzip ZIP64 files.<ref>{{cite web | url=https://superuser.com/questions/114011/extract-large-zip-file-50-gb-on-mac-os-x | title=Extract large zip file (50 GB) on Mac OS X | access-date=17 Dec 2018 }}</ref> More recent{{when|date=March 2020}} versions of Mac OS ship with info-zip's zip and unzip command line tools which do support Zip64: to verify run zip -v and look for "ZIP64_SUPPORT".
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)