New project: arm disassembler and decompiler
Hi there,
a new project, again written in python for better study purpose, covers my time right now. Right now I just want to give you a short preview - not releasing the scripts so far. The scripts are in a very young stadium, not covering many cases and just decompiling quite simple functions.
The idea for writing these scripts came upon me while searching for a way to decompile apps from idevices like iphone, ipad and ipod. HexRays Decompiler is no option for me since its outragious pricing. The ARM cpu is quite simple, much more simple than x86/64 stuff. Implementing the disassembly of the mach-o files just took about two or three days.
Much more complicated is understanding all that objective-c stuff, the different sections with non-lazy symbols, lazy symbols, string-, class-, and method-references and so on. So thats what I am working on right now - putting the disassembled stuff into the right order, generating readable c-like code (which does not yet compile out of the box for missing declarations and missing external symbols).
Still the first examples are quite impressive, which makes me keeping up the work. For testing my scripts I am using the MusicLibrary framework from my iphone 4, iOS 5.1.1. This mach-o dylib contains lots of functions dealing with the - who would have guessed - music library of the device. In the following you will see the first function of that library, decompiled by j-arm, still missing some stuff like declarations...
Examples
Pure Assembler | Decompiled Function |
---|---|
disassembling function at 0x10C4 (sub_10C4) | void +[ML3MusicLibrary initialize](arg_R0) { |