Как декомпилировать exe python
Перейти к содержимому

Как декомпилировать exe python

LookiMan / EXE2PY-Decompiler Goto Github PK

С помощью данной программы можно декомпилировать исполняемые файлы, созданные с помощью pyinstaller или py2exe.

Также возможно декомпилировать отдельные кэш-файлы назад в исходный код python.

Скриншот главного окна приложения

Что нового

Полностью переработан графический интерфейс

Добавлена поддержка DRAG & DROP для LineEdit

Добавлена возможность указывать папку для декомпиляции её содержимого

Значительно переписан код

Фиксы:

Исправлена проблема с декомпиляции кода версии 3.6 старшими версиями python

Добавлена возможность прерывания процесса декомпиляции

Добавлен баннер, появляющийся во время работы декомпилятора

Примечание:

Если не удается декомпилировать одну из библиотек с папки EXE2PY_Pycache переключите флажок «декомпилировать все дополнительные библиотеки» в активное положение и повторите попытку.

Программа может работать на версиях python 3.4, 3.6, 3.7. С её помощью, возможно, декомпилировать программы ранее перечисленных версий python. При этом различие версий не играет никакой роли. (С помощью python версии 3. 4. можно декомпилировать программу, написанную на python 3. 6.).

Скриншот работающего приложения

EXE2PY-Decompiler’s People

Contributors

Stargazers

Watchers

Forkers

EXE2PY-Decompiler’s Issues

TypeError: stat: path should be string, bytes, os.PathLike or integer, not NoneType

arch . extractFiles ()

/D/p/c/p/t/EXE2PY-Decompiler [master]× » py37 pyinstxtractor.py «exe/.exe» -1- 20:16:17
pyinstxtractor.py:87: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module’s documentation for alternative uses
import imp
[>] Processing exe/
.exe
[>] Pyinstaller version: 2.1+
[>] Python version: 309
[>] Length of package: 26502589 bytes
[>] Found 1017 files in CArchive
[>] Beginning extraction. please standby
Traceback (most recent call last):
File «pyinstxtractor.py», line 367, in
main()
File «pyinstxtractor.py», line 359, in main
arch.extractFiles()
File «pyinstxtractor.py», line 251, in extractFiles
if not os.path.exists(EXTRACTION_DIR):
File «/usr/lib/python3.7/genericpath.py», line 19, in exists
os.stat(path)
TypeError: stat: path should be string, bytes, os.PathLike or integer, not NoneType

скрипт не стартует

Python 3.8.6rc1
скрипт не стартует, появляется ошибка:

Как можно связаться с вами?

Recommend Projects

React

A declarative, efficient, and flexible JavaScript library for building user interfaces.

Vue.js

�� Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

Typescript

TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

TensorFlow

An Open Source Machine Learning Framework for Everyone

Django

The Web framework for perfectionists with deadlines.

Laravel

A PHP framework for web artisans

Bring data to life with SVG, Canvas and HTML. ������

Recommend Topics

javascript

JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

Some thing interesting about web. New door for the world.

server

A server is a program made to process requests and deliver data to clients.

Machine learning

Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

Visualization

Some thing interesting about visualization, use data art

Some thing interesting about game, make everyone happy.

Recommend Org

Facebook

We are working to build community through open source technology. NB: members must have two-factor auth.

How to decompile compiled .pyc Python files

How to use uncompyle6 to decompile .pyc files in your directory.

Step 1. Install uncompyle6

uncompyle6

A native Python cross-version decompiler and fragment decompiler. The successor to decompyle, uncompyle, and…

A native Python cross-version decompiler and fragment decompiler. The successor to decompyle, uncompyle, and…

More from Cassandra

Brief notes and tutorials on quantitative cryptocurrency research, and Python and R programming tips for data science

python exe decompile

the driving life sample is packaged in python exe file attempted to decompile to py file.

use pyinstxtractor. py generate pyc files 。

the actual attempt found that direct decompilation would report an error

see ahead using pyinstxtractor. py there is a hint in the decompilation error “not a pyinstaller archive”, the py script used for extraction is called archive_viewer.py( use the archive _viewer.py to install pyinstaller, pass pip install pyinstaller you can install )

methods a 、 use the archive _viewer.py extract the pyc

archive_viewer.py the command

because with pyinstaller after packing ,pyc the first 8 bytes of the file are erased , so add it back yourself at the end.

the first four bytes are the compiled version of python , the last four bytes are timestamps. ( four bytes of magic number、 four byte timestamp )

for a compiled version, look at the struct in the packaged file ,so so again, we’re extracting this struct file

open with the hexadecimal editor struct file before copying it 8 bytes

added to the ii. pyc in the

then use tools to decompile pyc py。

** available uncompyle *.pyc decompile pyc file to get py**

method 2 、 use pyinstxtractor. py extract the pyc

use pyinstxtractor directly. py to extract the exe file pyc error will be reported, need to remove the signature information before using pyinstxtractor.py unlock

first remove the signature from the exe file

check the pyinstaller source code for this ,PyInstaller first, the program will read the last data to identify, if it is in line with the format will be parsed (c/Program Files/Python/Python37/Lib/site-packages/PyInstaller/archive/reader.py)

MAGIC is where you start identifying at the end of the file.

pyinstaller2.0 it includes magic 24 byte length

pyinstaller2.1 it includes magic 88 byte length

\014\013\012\013\016 is eight into the system , can be converted to hexadecimal view

open using the hexadecimal editor svchost.exe, move forward from the last mei to find a match MAGIC the whole structure.

since mei , select back 88 bytes in length , delete all the rest ( delete the formatted data )。

and then you’re done and you sign.

finally, we use pyinstxtractor directly. py extract it. we also need to fix the header data as before , same way as above.

Добавить комментарий

Ваш адрес email не будет опубликован. Обязательные поля помечены *