Introduction
ida2sql is the Python module in charge of exporting the disassembly information from IDA into the SQL Schema we developed in Sabre-Security for our BinNavi product. I'm currently the main developer and maintainer of this module at Sabre Security, so I'm the guy to blame with any problems you find. The latest version can be found here together with its changeset and usage examples.
It can currently export Intel and PPC architectures, ARM support is experimental
ida2sql needs IDAPython and can be run in batch mode. It's included in BinNavi but it's also available as a stand-alone module for anybody to use.
The module is distributed as two files:
- ida2sql.py is the file run from IDA, it just starts the main part of the code in the ZIP file
- ida2sql.zip is a zipped Python module implementing all the functionality
Download
ida2sql can be downloaded here as ZIP or as tar.gz
Installation
Drop the ZIP file inside the IDA plugins directory then, in order to use it, just run the ida2sql.py script from within IDA with IDAPython
Usage
Once the installation is completed, run ida2sql.py with IDAPython. If not configuration file exists, the script will prompt for the database information, otherwise it will immediately start exporting. This can take a while.
Once finished the information will be in the dabase. Taking a look at the SQL Schema will give ideas of what to do next.
The configuration file
If a file named ida2sql.cfg is placed in the IDA top level folder the database information (user, password, host) will be loaded from it. Allowing for quickly exporting by just running ida2sql.py from within IDA.
See the example ida2sql.cfg file included.
After the installation is completed it'll be possible to export the disassembly information from IDA into a MySQL database, which allows for lots of interesting datamining possibilities.
Requirements
- IDA 5.0 and 5.1
- IDAPython 0.8 and 0.9
- Python 2.4 or higher
- MySQLdb 1.2.2 (Python MySQL bindings)
- MySQL 5.0