If you don't know neither the enemy
nor yourself, you will sucumb in every battle.
If you know yourself but not the enemy, for every victory gained you will also suffer a defeat.
But if you know the enemy and know yourself you need not fear the result of a hundred battles.
The art of war (Sun Tzu)
The pytnsproxy tool
This is the proof of concept code for a presentation that I gave at Hacktivity 2009. It implements the following attacks:
It is released under GPLv2 and use at your own responsibility.
The current version is 0.1 and it is a PoC code, thus it needs a massive code cleaning, refactoring and bug hunting. This version can be called the “just works” version. The source can be downloaded from here.
Prerequisites It was tested on Windows and Linux with the followings:
Pyhton 2.6 python-configobj-4.6.0 bitstring-0.5.2 OpenSSL to compile the aesdecrypt module boost-1.37.0 to compile the aesdecrypt module, it uses the boost_python library
On Linux systems just unpack the archive and run “make”. If the necessary libraries are installed it will compile the aesdecrypt.cpp. If the SELinux is enabled you will got an error message when you run pytnsproxy:
You can use the following command:
Please read the SELinux documentation for more details.
I successfully compiled the aesdecrypt.cpp with Visual Studio 2008 express, Boost 1.39 and OpenSSL. You can find an example Jamroot file in the source distribution. You need an user-config.jam file in your home directory:
Start the Visual Studio 2008 Command Prompt and set the BOOS_BUILD_PATH environment variable:
Adjust the Jamroot file for your environment. Then start bjam:
Copy the aespython.pyd file from bin\msvc-9.0\release\link-static\threading-multi\ folder to the base folder of pytnsproxy.
The views, opinions and thoughts in this homepage are the views, opinions and thoughts of the writer of this homepage and do not represent the views, opinions or thoughts of any past or current employer of the writer or any other third person. The content is provided 'as is' without warranty of any kind. Use at your own responsibility. Laszlo may be contacted on firstname.lastname@example.org.