Show HN: A Ghidra extension that turns programs back into object files

https://github.com/boricj/ghidra-delinker-extension
by boricj • 3 years ago
7 4 3 years ago

Hi all, I've been working on tooling that can reverse the work of a linker. It allows one to take bits and pieces of an executable and delink them into working object files, which can then be reused as-is to make new programs or libraries, without having to decompile or disassemble them first.

The readme has links to my blog demonstrating some of the use-cases. The most impressive one so far is making a port of a ~100 KiB Linux a.out i386 program to a native Windows PE i386 executable, despite not having access to its original source code or even decompiling it.

Currently, 32-bit i386 and MIPS instruction sets are supported, with exportation to ELF object files. Additional ISAs and object file formats can be added by writing a relocation synthesizer and an exporter, respectively.

Related Stories

Loading related stories...

Source preview

github.com