The items appearing below are proposed for inclusion in the next APPNOTE release. Please review and post any questions or comments to firstname.lastname@example.org.
Alignment Extra Field (3rd Party):
Proposed by: Zbynek Vyskovsky of Apache Commons-Compress
Defined Need: Requests a standard Extra Field which specifies required alignment of the file within the zip file:. Considered to be useful when zip serves as a container format (Android applications, virtual filesystem for games, embedded database etc.).
4.6.xx -Data Stream Alignment (0xa11e):
Defines alignment of data stream of this entry within the zip archive. Additionally, indicates whether the compression method should be kept when re-compressing the zip file.
The purpose of this extra field is to align specific resources to word or page boundary so they can be easily mapped into memory.
Value Size Description
----- ---- -----------
0xa11e Short tag for this extra block type
TSize Short total data size for this block (2+padding)
alignment Short required alignment and indicator
0x00 Variable padding
The alignment field (lower 15 bits) defines the minimal alignment required by the data stream. Bit 15 of alignment field indicates whether compression method of this entry
can be changed when recompressing the zip file. 0 means the compression method should be kept, 1 indicates the compression method can be changed.
The padding field contains padding to ensure the correct alignment and can be changed at any time when the offset changes or required alignment changes.