2015-08-21 10:04:50 +03:00
|
|
|
This documentation explains how to install Python binding for Unicorn
|
2015-10-15 18:51:31 +03:00
|
|
|
from source.
|
2015-08-21 10:04:50 +03:00
|
|
|
|
|
|
|
|
|
|
|
0. Install the core engine as dependency
|
|
|
|
|
|
|
|
Follow README in the root directory to compile & install the core.
|
|
|
|
|
2015-11-01 16:50:06 +03:00
|
|
|
On *nix, this can simply be done by (project root directory):
|
2015-08-21 10:04:50 +03:00
|
|
|
|
|
|
|
$ sudo ./make.sh install
|
|
|
|
|
|
|
|
|
2015-11-01 16:50:06 +03:00
|
|
|
1. To install pure Python binding on *nix, run the command below in the Python bindings directory:
|
2015-08-21 10:04:50 +03:00
|
|
|
|
|
|
|
$ sudo make install
|
|
|
|
|
|
|
|
To install Python3 binding package, run the command below:
|
|
|
|
(Note: this requires python3 installed in your machine)
|
|
|
|
|
|
|
|
$ sudo make install3
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This directory contains some sample code to show how to use Unicorn API.
|
|
|
|
|
|
|
|
- sample_<arch>.py
|
|
|
|
These code show how to access architecture-specific information for each
|
|
|
|
architecture.
|
|
|
|
|
|
|
|
- shellcode.py
|
|
|
|
This shows how to analyze a Linux shellcode.
|
|
|
|
|
2015-10-15 18:51:31 +03:00
|
|
|
- sample_network_auditing.py
|
|
|
|
This shows how to analyze & interpret Linux shellcode.
|
2015-08-21 10:04:50 +03:00
|
|
|
|
|
|
|
|
2015-10-15 18:51:31 +03:00
|
|
|
2. To install Python binding on Windows:
|
2015-08-21 10:04:50 +03:00
|
|
|
|
2015-10-15 18:51:31 +03:00
|
|
|
Run the following command in command prompt:
|
2015-08-21 10:04:50 +03:00
|
|
|
|
|
|
|
C:\> C:\location_to_python\python.exe setup.py install
|
|
|
|
|
2015-10-15 18:51:31 +03:00
|
|
|
Next, copy all the DLL files from the 'Core engine for Windows' package available
|
2015-08-21 10:04:50 +03:00
|
|
|
on the same Unicorn download page and paste it in the path:
|
|
|
|
|
|
|
|
C:\location_to_python\Lib\site-packages\unicorn\
|