Crates.io | ota-dump |
lib.rs | ota-dump |
version | 0.1.6 |
source | src |
created_at | 2021-09-21 20:52:05.3805 |
updated_at | 2022-09-02 18:21:18.924438 |
description | A tool to dump manifest of Android's OTA package |
homepage | |
repository | |
max_upload_size | |
id | 454608 |
size | 84,783 |
update_metadata.proto is copied from aosp
Android's OTA file is simply a .zip archive. Most of the information is stored in payload.bin
entry inside it.
Format of payload.bin
is defined at system/update_engine/update_metadata.proto.
This tool locates payload.bin
inside OTA's zip file and parses the format according to definition in update_metadata.proto.
cargo install ota-dump
ota-dump <path to android OTA.zip>
ota-dump coral_ota.zip
Dump the entire OTA manifest in json format. Dumped object has type DeltaArchiveManifest. This object is huge so it's best to save it to a file or pipe to other CLI tools such as jq
ota-dump cf_x86_dm_verity.zip | jq '.partitions[].partition_name'
will list partitions included in this update.
ota-dump cf_x86_dm_verity.zip | jq '{name: .partitions[].partition_name, size: .partitions[].new_partition_info.size}'
List partitions included and size of partitions after OTA update.
ota-dump cf_x86_dm_verity.zip | jq 'del(.partitions[].operations)|del(.partitions[].merge_operations)'
Dump the manifest without operation list without list of operations. The output will be much smaller.