Что такое формат файла PACK?
A .pack file is a Pack200 data archive container used for storing compressed JAR files for easier network download. .pack files are typically saved with an additional .gz suffix - the standard delivery bundle is named .jar.pack.gz and produced by Java's pack200 command-line tool.
A JAR is a ZIP archive that also serves as the executable format for the Java virtual machine. Pack200, standardised in 2004 under JSR 200, re-encodes a JAR's class-file constant pools using a specialised binary algorithm; combined with GZIP, a .pack.gz file can be up to 60% smaller than the original JAR and hence significantly faster to download - the primary goal of the format for Java Web Start and browser applet delivery.
Pack200 is now obsolete. Oracle deprecated the pack200 and unpack200 command-line tools in Java 11 (JEP 336, 2018) and removed them entirely in Java 14 (2020). Legacy .pack or .pack.gz files can only be decompressed using a JDK 8-13 environment; the raw .pack stream begins with the magic number 0xCAFED00D.
Безопасность и защита
РИСК: MEDIUMA .pack itself is inert data, but it decompresses to a Java JAR containing executable bytecode - only unpack and run JARs from sources you trust, since a malicious JAR can run arbitrary code under the JRE. Pack200 was a known historical attack surface (CVEs in the unpacker), so use a current JDK build when unpacking. Avoid third-party "PACK opener" download portals; use Oracle/Adoptium JDKs for unpack200 instead.
Детали формата
в двух словах- Git packfile (.pack) - Inside .git/objects/pack, Git stores objects in binary .pack files (with a .idx index); managed by Git, never opened by hand.
- Minecraft / game resource pack (.pack) - Some games and modpacks use .pack for bundled resources or texture packs; structure is engine-specific (often ZIP-based).
- Skype / app data pack (.pack) - Various applications write internal '.pack' data blobs; meaning depends entirely on the program.
Программы, открывающие файлы PACK
Технические подробности
глубокая спецификация| Format type | Binary Pack200 compressed-JAR container |
| Magic number | 0xCAFED00D at byte offset 0 in the raw .pack stream; GZIP header 0x1F8B at offset 0 in the common .pack.gz form |
| Byte order | Big-endian |
| Compression | Pack200 constant-pool re-encoding algorithm; outer GZIP/DEFLATE applied in the standard .pack.gz delivery form |
| Compression ratio | Up to ~60% smaller than the equivalent plain-GZIP-compressed JAR |
| MIME type | application/x-java-pack200 |
| Specification | JSR 200 - Network Transfer Format for JAR Files (Java SE 5.0, introduced 2004) |
| Max archive entries | Inherits the JAR/ZIP 65,535-entry ceiling |
| Encryption | None; existing JAR code-signing signatures are preserved and round-tripped by pack200/unpack200 |
| Integrity checking | GZIP CRC-32 on the .pack.gz outer wrapper; JAR signatures verified independently after unpacking |
| Typical file size | 50 KB - 20 MB (always smaller than the source JAR it encodes) |
| Status | Deprecated in Java 11 (JEP 336, 2018); pack200 and unpack200 tools removed in Java 14 (2020) |
| Unpack tools | unpack200 (JDK 8-13 only); also 7-Zip on Windows for inspection |
| Primary use case | Minimising JAR download size for Java Web Start applications and browser applets |
| Compatible platforms | Windows, Linux, macOS - any platform with JDK/JRE 8-13 installed |
| Выпущен | 2004 (Java SE 5.0 / J2SE 1.5 - JSR 200 'Network Transfer Format for JAR Files') |
| Последняя версия | Pack200 as specified through JSR 200; deprecated in Java 11 (2018), removed in Java 14 (2020) |
| Открыть стандартное | Да · без роялти |
| Спецификация | docs.oracle.com |
Конвертации PACK
Вопросы и ответы сообщества
спрошено пользователямиВопросов пока нет - станьте первым, кто спросит о файлах PACK.