| Offset | Size | Description |
|---|---|---|
| 0x0 | 8 | 'Magic' value: "dex\n009\0" |
| 0x8 | 4 | Checksum |
| 0xC | 20 | SHA-1 Signature |
| 0x20 | 4 | Length of file in bytes |
| 0x24 | 4 | Length of header in bytes (currently always 0x5C) |
| 0x28 | 8 | Padding (reserved for future use?) |
| 0x30 | 4 | Number of strings in the string table |
| 0x34 | 4 | Absolute offset of the string table |
| 0x38 | 4 | Not sure. String related |
| 0x3C | 4 | Number of classes in the class list |
| 0x40 | 4 | Absolute offset of the class list |
| 0x44 | 4 | Number of fields in the field table |
| 0x48 | 4 | Absolute offset of the field table |
| 0x4C | 4 | Number of methods in the method table |
| 0x50 | 4 | Absolute offset of the method table |
| 0x54 | 4 | Number of class definitions in the class definition table |
| 0x58 | 4 | Absolute offset of the class definition table |
| Offset | Size | Description |
|---|---|---|
| 0x0 | 4 | Absolute offset of the string data |
| 0x4 | 4 | Length of the string (not including the null-terminator) |
| Offset | Size | Description |
|---|---|---|
| 0x0 | 4 | String index of the name of the class |
| Offset | Size | Description |
|---|---|---|
| 0x0 | 4 | Class index of the class this field belongs to |
| 0x4 | 4 | String index of the field name |
| 0x8 | 4 | String index of the field type descriptor |
| Offset | Size | Description |
|---|---|---|
| 0x0 | 4 | Class index of the class this field belongs to |
| 0x4 | 4 | String index of the method name |
| 0x8 | 4 | String index of the method type descriptor |
| Offset | Size | Description |
|---|---|---|
| 0x0 | 4 | Class index |
| 0x4 | 4 | Access Flags (not 100% sure what this is for, I think it has to do with private/protected/public status) |
| 0x8 | 4 | Index of superclass |
| 0xC | 4 | Absolute offset of interface list |
| 0x10 | 4 | Absolute offset of static field list |
| 0x14 | 4 | Absolute offset of instance field list |
| 0x18 | 4 | Absolute offset of direct method list |
| 0x1C | 4 | Absolute offset of virtual method list |
| Offset | Size | Description |
|---|---|---|
| 0x0 | 8 | Index of string or object constant or literal "primitive" constant |
| Offset | Size | Description |
|---|---|---|
| 0x0 | 4 | Method index |
| 0x4 | 4 | Access flags (not 100% sure what this is for, I think it has to do with private/protected/public status) |
| 0x8 | 4 | Throws list off (no idea what this is) |
| 0xC | 4 | Absolute offset of header for code that implements the method |
| Offset | Size | Description |
|---|---|---|
| 0x0 | 2 | Number of registers used by this method |
| 0x2 | 2 | Number of inputs this method takes (includes "this" pointer for non-static methods) |
| 0x4 | 2 | Output size? (presumably the size of whatever object the method returns) |
| 0x6 | 2 | Padding |
| 0x8 | 4 | String index of the source file name this method is implemented in |
| 0xC | 4 | Absolute offset of the actual code that implements this method |
| 0x10 | 4 | Absolute offset of the list of exceptions this method can throw (not 100% sure) |
| 0x14 | 4 | Absolute offset of the list of address and line number pairs for debugging purposes |
| 0x1C | 4 | Absolute offset of the local variable list of this method (includes arguments to the method and "this") |
| Offset | Size | Description |
|---|---|---|
| 0x0 | 4 | Start (not a clue) |
| 0x4 | 4 | End (not a clue) |
| 0x8 | 4 | String index of variable name |
| 0xC | 4 | String index of variable type descriptor |
| 0x10 | 4 | Register number this variable will be stored in (not 100% sure) |