Government of the Republic of Trinidad and Tobago
gov.tt

Cisco Releases GhIDA And Ghidraaas Tools For IDA Pro

Cisco Releases GhIDA And Ghidraaas Tools For IDA Pro

Cisco Talos has released two new open source tools for IDA Pro, namely GhIDA, an IDA Pro plugin, and Ghidraaas (Ghidra as a Service), a docker container.

The GhIDA plugin integrates the National Security Agency (NSA)’s open-source Ghidra decompiler in the IDA workflow, aiming to provide users with improved navigation and comments, and allowing them to rename and highlight symbols.
GhIDA is suitable for reverse-engineering by decompiling x86 and x64 PE and ELF binary functions either with the help of a local installation of Ghidra, or through Ghidraaas, a docker container that exposes the decompiler through REST APIs, Talos reveals.

Features that the new IDA plugin comes with include synchronization of the disassembler view with the decompiler view, decompiled code syntax highlighting as C code using the pygments Python library, code navigation by double-clicking on a symbol name, the ability to insert and update comments in the decompiler view using the default IDA shortcut, the ability to highlight and rename symbols in the decompiler view, and the storing of decompiled code and comments when IDA is closed.

GhIDA requires IDA Pro 7.x as well as two additional Python2 libraries, namely pip2 install requests and pip2 install pygments.

To install the plugin, one would need to clone or download the GhIDA repository and copy ghida.py and the ghida_plugin folder in the plugins folder of the IDA Pro installation.

When launching GhIDA for the first time (Ctrl+Alt+D or Edit -> Plugins -> GhIDA Decompiler), one can choose between a local Ghidra installation and the Ghidraaas server. The former requires Ghidra to be installed on the machine and for the path of the Ghidra folder to be added to the installation path.

GhIDA was designed to export the IDA project using the idaxml.py Python library shipped with Ghidra, and to invoke Ghidra in headless mode to fetch the decompiled code, without additional analysis.

At first launch, the idaxml library is used to create two files: an XML file embedding a program description according to the IDA analysis (functions, data, symbols, comments, etc.) and a file containing the binary code of the analyzed program.

The XML is recreated each time the GhIDA cache is flushed, to take into account updates made in the analysis. The FunctionDecompile.py Ghidra plugin is used to obtain the decompiled code.