The Perl x86 Disassembler is a Perl-based Intel x86 disassembler that is designed for reliable and efficient disassembly of binary code. Its compact, portable, and customizable architecture is ideal for reverse engineering and malware analysis.
Derived from libi386.so in the bastard project, this disassembler is x86 specific and won't expand to cover other CPU architectures. Although not a standalone project, it's a standalone library that is automatically generated alongside releases of the bastard project.
The recent popularity of objdump output analyzers shows that many people, mostly non-programmers, want to write disassemblers without having much knowledge or interest in C programming. To address such needs, many "disassemblers" are written in Perl.
The basic usage of libdisasm library involves initializing the library, disassembling stuff, and un-initializing it. Disassemble_init(), disassemble_cleanup(), and disassemble_address() are the three routines with following prototypes:
int disassemble_init(int options, int format);
int disassemble_cleanup(void);
int disassemble_address(char *buf, int buf_len, struct instr *i);
Instructions disassembled produce an intermediate format, and the sprint_address() can be used to generate a string representation instead of an intermediate one. One can use C code to implement a simple disassembler using these routines.
The recommended usage of libdisasm involves analyzing the disassembled instruction's type and operand type fields, cues for xref generation, syntax highlighting, and control flow tracking. It's a useful software tool that provides basic disassembly of Intel x86 instructions.
Version 0.16: N/A