Format:VDEX
| Platforms | Android ART 8.0 and later |
|---|---|
| Magic | 76 64 65 78 + ASCII version ("vdex006\0") |
| Extensions | .vdex |
| On this wiki | Facts · Code · Notes · Topics |
Android ART verification-dependencies file (.vdex), written next to an OAT file since Android 8.0: magic "vdex", a 4-digit ASCII version, the number of DEX files, and the sizes of the DEX, verifier-deps and quickening sections.
Header (versions 6, 10, 11 as modelled by LIEF)
magic[4] vdex; version[4] ASCII digits (006\0, 010\0, 011\0); number_of_dex_files u32; dex_size u32; verifier_deps_size u32; quickening_info_size u32. After the header: one u32 checksum per DEX file, then the DEX files themselves (from OAT 131 / Android 8.1 dex2oat may keep the DEX only here and not in the OAT), then the verifier dependencies and the quickening info (a compact table that restores quickened -quick instructions to the original opcodes).
Versions
VDEX 006 is Android 8.0, 010 is Android 8.1, 011 Android 9 (LIEF maps 6 and 10 explicitly; 11 as comment only). ART main (AOSP, commit 6484611f) is at version 027 with a different header: vdex, 027\0, u32 number_of_sections, followed by {u32 kind, u32 offset, u32 size} section headers; kinds are 0 checksums (one u32 per DEX), 1 DEX files, 2 verifier dependencies, 3 type lookup table. The quickening-info section of the old header is not in this layout. See Fact:VDEX/struct/VDEX header version 027 with sections. Unverified: which version numbers between 011 and 027 shipped in which Android release, and where cdex (Format:DEX) appears; check older vdex_file.h revisions in the AOSP history.
Use: extract the DEX files from a .vdex to recover the app code after the APK was removed or the OAT holds only compiled code. See Format:DEX and Format:OAT.
Code & repositories
- https://github.com/lief-project/LIEF @
2795838f5f33efbc10f071d194c44197a86a36d8· license: Apache-2.0 (declared by the contributor for the files used; GitHub reports Apache-2.0 (read from LICENSE; GitHub's API was busy) for the repository)
LIEF: parser and rewriter for ELF, PE, Mach-O, DEX, OAT, VDEX and ART; src/DEX, src/OAT, src/VDEX, src/ART Structures.hpp give the header layouts per Android release
Tested on: source read, not run: source read only · checked 2026-10-18