讯享网
https://juejin.cn/post/
[local file header 1]
[file data 1]
[data descriptor 1]
.
.
.
[local file header n]
[file data n]
[data descriptor n]
[central directory]
[end of central directory record]
讯享网
-
Local file header
讯享网
compression method: (2 bytes)
(see accompanying documentation for algorithm
descriptions)
0 - The file is stored (no compression)
1 - The file is Shrunk
2 - The file is Reduced with compression factor 1
3 - The file is Reduced with compression factor 2
4 - The file is Reduced with compression factor 3
5 - The file is Reduced with compression factor 4
6 - The file is Imploded
7 - Reserved for Tokenizing compression algorithm
8 - The file is Deflated
9 - Enhanced Deflating using Deflate64(tm)
10 - PKWARE Data Compression Library Imploding
11 - Reserved by PKWARE
12 - File is compressed using BZIP2 algorithm
-
File data
-
Data descriptor
Data descriptor:
crc-32 4 bytes
compressed size 4 bytes
uncompressed size 4 bytes
This descriptor exists only if bit 3 of the general
purpose bit flag is set (see below). It is byte aligned
and immediately follows the last byte of compressed data.
This descriptor is used only when it was not possible to
seek in the output .ZIP file, e.g., when the output .ZIP file
was standard output or a non seekable device. For Zip64 format
archives, the compressed and uncompressed sizes are 8 bytes each.
-
案例展示
-
File header
-
End of central directory record
-
A1: 签名区块起始偏移 -
B2: 中心目录区起始位置
-
0X043E8D -
长度:05 6E -
ID:71 09 87 1A
-
偏移量:0x0443FB -
长度:0A 62 -
ID: 72 42 65 77
-
https://pkware.cachefly.net/webdocs/APPNOTE/APPNOTE-6.2.0.txt -
http://androidxref.com/9.0.0_r3/ -
https://www.youtube.com/watch?v=_a_keel8JFI -
https://source.android.com/docs/security/features/apksigning/v2?hl=zh-cn#apk-signing-block


版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容,请联系我们,一经查实,本站将立刻删除。
如需转载请保留出处:https://51itzy.com/kjqy/155429.html