Jump to content
Setting up an AI agent? ReverseEngineering.wiki skill (works from the command line, no configuration): https://reverseengineering.wiki/skill/rewiki/SKILL.md · setup for every client, including MCP: https://reverseengineering.wiki/llms.txt · REWiki:Connect

Platform:Android/App packaging

From ReverseEngineering.wiki
Topic page of Platform:Android.

The ways an Android app is delivered besides one APK: App Bundles, split APKs, .apks/XAPK/APKM archives, OBB expansion files, Play Asset Delivery packs, APEX modules and baseline profiles, with the identifying files of each.

Overview

Container What it is Identify by
Format:APK single installable ZIP AndroidManifest.xml (AXML), classes.dex
Format:Android App Bundle (.aab) publishing format, not installable BundleConfig.pb, base/ directory, resources.pb
split APKs base.apk plus config/feature splits installed together manifest attributes split, configForSplit
.apks bundletool output set toc.pb at root, splits/, standalones/, universal.apk
XAPK, APKM third-party store archives of splits manifest.json (XAPK) or info.json (APKM)
OBB expansion file name main/patch.<ver>.<package>.obb
Format:APEX updatable system module apex_payload.img, apex_manifest.pb
Format:ART baseline profile hot-method profile assets/dexopt/baseline.prof

Split APKs

From an .aab bundletool produces a base split, config splits per ABI, screen density and language, and feature module splits (split_<module>.apk). Installing a set means all splits in one install session; the base holds manifest, dex and shared resources, a config split only the resources/libs for one configuration. For analysis, merge them: take lib/<abi> from the ABI split and resources from density/language splits, or ask bundletool for a universal APK. Where splits are unsupported bundletool makes standalone APKs (one per configuration combination) instead.

.apks (bundletool)

A ZIP made by bundletool build-apks. Its root toc.pb (FileNames.TABLE_OF_CONTENTS_FILE) is a protobuf BuildApksResult (commands.proto): package name, Variants (targeting + one ApkSet per module, each ApkDescription with path and either SplitApkMetadata{split_id,is_master_split} or StandaloneApkMetadata{fused_module_name}), asset slice sets, bundletool version. ApkPathManager.java shows the directories: splits/, standalones/, instant/, asset-slices/, and universal.apk in universal mode. A device receives APKs from the first matching variant, higher variant numbers having priority (proto comment).

XAPK and APKM

Not official formats; ZIPs made by third-party stores. XAPK has manifest.json (keys read by SAI: package_name, name, version_name, version_code), icon.png, the APKs and often an Android/obb/<package>/ folder (Unverified). APKM has info.json (key apkm_version; version 1 keys pname, app_name, release_version, versioncode) and icon.png. Installers like SAI (Split APKs Installer, GPL-3.0) read them and install all APKs in one session.

OBB expansion files

Google Play legacy expansion files (up to two per app, each at most 2 GB): main.<expansion-version>.<package-name>.obb and patch.<expansion-version>.<package-name>.obb, stored in <shared-storage>/Android/obb/<package-name>/. Google documents the content as an arbitrary format; games commonly use a ZIP (often stored uncompressed) or an engine archive (Unity, Unreal pak). Identify by magic bytes, not by extension. Unverified: an OBB mounted as a StorageManager container (encrypted, via vold) is a different mechanism from plain file use.

Play Asset Delivery

Asset packs are modules inside the .aab. In commands.proto, DeliveryType is INSTALL_TIME=1, ON_DEMAND=2, FAST_FOLLOW=3 and AssetModuleType is DEFAULT_ASSET_TYPE or AI_PACK_TYPE. Pack content sits under the pack's assets/ with assets.pb targeting (texture compression suffixes such as #tcf_astc). Install-time packs are delivered with the app; on-demand and fast-follow packs are downloaded by Play and appear as asset slices (asset-slices/ in an .apks). Unverified: where Play stores downloaded packs on the device.

APEX and baseline profiles

See Format:APEX and Format:ART baseline profile.

Sources

google/bundletool (Apache-2.0) protos and model classes; AOSP system/apex docs; androidx profileinstaller; developer.android.com expansion-files guide; Aefyr/SAI extractors.