Disassemble ELF binary without section headers (program headers only) using objdump
6
votes
1
answer
4096
views
I've got an ELF binary that contains nothing but two LOAD segments in the program header table, one for code and one for data.
readelf -a
tells me there's no section headers.
If I attempt do disassemble the ARM binary on my amd64 machine with ARM cross binutils, it doesn't give me proper output. However, as far as I understand, the binary's architecture shouldn't be relevant for this question, since the issue is ELF-related.
$ file ./binary
./binary: ELF 32-bit LSB executable, ARM, EABI5 version 1 (GNU/Linux), statically linked, stripped
$ arm-linux-gnueabi-objdump -d ./binary
./binary: file format elf32-littlearm
$ arm-linux-gnueabi-objdump -x ./binary
./binary: file format elf32-littlearm
./binary
architecture: arm, flags 0x00000102:
EXEC_P, D_PAGED
start address 0x0004c8d8
Program Header:
LOAD off 0x00000000 vaddr 0x00010000 paddr 0x00010000 align 2**16
filesz 0x0003d27e memsz 0x0003d27e flags r-x
LOAD off 0x00005c78 vaddr 0x00085c78 paddr 0x00085c78 align 2**16
filesz 0x00000000 memsz 0x00000000 flags rw-
STACK off 0x00000000 vaddr 0x00000000 paddr 0x00000000 align 2**4
filesz 0x00000000 memsz 0x00000000 flags rw-
private flags = 5000400: [Version5 EABI] [hard-float ABI]
Sections:
Idx Name Size VMA LMA File off Algn
SYMBOL TABLE:
no symbols
**Is there a way to make objdump disassemble ELF segments?**
Asked by ulmer-a
(229 rep)
Aug 18, 2019, 06:59 PM
Last activity: Nov 7, 2024, 02:03 PM
Last activity: Nov 7, 2024, 02:03 PM