#header #chunk #file-header #sparse #image #android #parser

android-sparse-image

Low-level Android sparse image parsing headers

2 releases

new 0.1.1 Nov 28, 2024
0.1.0 Nov 24, 2024

#10 in #file-header

Download history 48/week @ 2024-11-18 224/week @ 2024-11-25

272 downloads per month
Used in fastboot-protocol

MIT/Apache

27KB
595 lines

Lowlevel android sparse image parsing helpers

An android space image is a sparse representation of a potential output file. The format consist of a [FileHeader] followed by a number of [ChunkHeader]s and their associated data

Sparse image
File header
Chunk 0 header
Chunk 0 data
Chunk 1 header
Chunk 1 data
....
Chunk N header
Chunk N data

The size of data in a chunk depends on the [ChunkType] and can be determined with ChunkHeader::data_size

Dependencies

~0.5–1MB
~22K SLoC