I have ARM (EABI and OABI) ELF binaries, and I'm using angr which uses libVEX. Unfortunately libVEX cannot parse OABI svc (swi) call, only EABI.
EABI svc call has format (where 45 is code of system call):
e3a0702d mov r7, #45
ef000000 svc 0x00000000
OABI has format (where 2d at the end):
ef90000c svc 0x0090000c
I would like to convert all ELF binaries such that, OABI above becomes:
push r7
mov r7, 0x0c
svc 0
pop r7
How can I do this? I'm thinking about python script, but the padding is important so I would probably need some framework which understands ELF.
User contributions licensed under CC BY-SA 3.0