C++ python bytecode disassembler and decompiler
  • C++ 84.5%
  • Python 14.9%
  • CMake 0.5%
Find a file
2011-10-09 15:43:24 -07:00
bin Added basic while loop support and a test system. 2010-12-31 02:42:58 -08:00
bytes Add Python 3.2 support 2011-01-06 17:15:48 -08:00
out Code so far 2009-07-24 08:35:21 +00:00
tests Test cases for try/except/finally stuff. 2011-10-02 19:01:07 -07:00
.gitignore Update .gitignore a bit 2011-10-02 19:47:18 -07:00
ASTNode.cpp Basic handling of try/except/finally blocks. 2011-10-01 19:40:34 -07:00
ASTNode.h Fixes for obscure loop conditions. 2011-10-09 15:43:24 -07:00
ASTree.cpp Fix and/or combiners for if statements. 2011-10-09 15:43:24 -07:00
ASTree.h Fixed imports, and restructured ifs to be "code blocks" 2010-09-07 21:32:34 -07:00
bytecode.cpp Actually output PyLong constants 2011-09-23 21:46:05 -07:00
bytecode.h Add Python 3.2 support 2011-01-06 17:15:48 -08:00
code.cpp Code so far 2009-07-24 08:35:21 +00:00
code.h A little bit of code support now 2009-07-26 10:07:13 +00:00
data.cpp Added the rest of the marshalable types, and more info to the disassembly output (including a bytecode position counter to help with jump calculations) 2009-07-25 02:41:15 +00:00
data.h Added the rest of the marshalable types, and more info to the disassembly output (including a bytecode position counter to help with jump calculations) 2009-07-25 02:41:15 +00:00
FastStack.h Slightly more consistent formatting 2011-09-18 23:55:27 -07:00
LICENSE Added GPL v3 license file 2009-07-25 00:43:46 +00:00
Makefile Fixes for obscure loop conditions. 2011-10-09 15:43:24 -07:00
module.cpp Add Python 3.2 support 2011-01-06 17:15:48 -08:00
module.h Add Python 3.2 support 2011-01-06 17:15:48 -08:00
numeric.cpp Fix Windows build 2011-10-02 12:14:54 -07:00
numeric.h Actually output PyLong constants 2011-09-23 21:46:05 -07:00
object.cpp Added the rest of the marshalable types, and more info to the disassembly output (including a bytecode position counter to help with jump calculations) 2009-07-25 02:41:15 +00:00
object.h Try to clean up the FastStack issues. 2010-12-30 16:48:59 -08:00
pycdas.cpp Actually output PyLong constants 2011-09-23 21:46:05 -07:00
pycdas.vcproj Fix Windows build 2011-10-02 12:14:54 -07:00
pycdc.cpp Merge uncommitted changes from old SVN copy 2010-09-03 21:50:35 -07:00
pycdc.sln Added windows/VS stuff 2010-04-12 12:59:44 -07:00
pycdc.vcproj Fix Windows build 2011-10-02 12:14:54 -07:00
PythonBytecode.txt Add Python 3.2 support 2011-01-06 17:15:48 -08:00
README.markdown Added README file. 2011-09-22 20:53:45 -07:00
sequence.cpp Decompyles classes and imports 2009-07-27 03:00:55 +00:00
sequence.h Decompyles classes and imports 2009-07-27 03:00:55 +00:00
string.cpp Properly check range when chars are signed 2011-10-02 19:51:54 -07:00
string.h Improved output formatting, and added more instruction support 2009-08-03 23:13:50 +00:00

Decompyle++

A Python Byte-code Disassembler/Decompiler

Decompyle++ aims to translate compiled Python byte-code back into valid and human-readable Python source code. While other projects have achieved this with varied success, Decompyle++ is unique in that it seeks to support byte-code from any version of Python.

Decompyle++ includes both a byte-code disassembler (pycdas) and a decompiler (pycdc).

As the name implies, Decompyle++ is written in C++. If you wish to contribute, please fork us on github at https://github.com/zrax/pycdc

Usage

To compile Decompyle++, just run make.

To run pycdas, the PYC Disassembler: ./bin/pycdas [PATH TO PYC FILE] The byte-code disassembly is printed to stdout.

To run pycdc, the PYC Decompiler: ./bin/pycdc [PATH TO PYC FILE] The decompiled Python source is printed to stdout. Any errors are printed to stderr.

Authors, Licence, Credits

Decompyle++ is the work of Michael Hansen and Darryl Pogue. It is released under the terms of the GNU General Public License, version 3.