A command line tool used to obfuscate python scripts, bind obfuscated scripts to fixed machine or expire obfuscated scripts.
The obfuscated script is a normal python script. With an extra extension module pytransform
, the plain Python scripts can be replaced with obfuscated ones seamlessly
And Pyarmor works well with py2exe, py2app, PyInstaller, cx_Freeze etc.
The byte code of each code object will be obfuscated as soon as code object completed execution, and f_locals of frame is cleared at the same time
Renames functions, methods, classes, variables, and arguments
Converts some Python functions to C functions and compiles them into machine instructions using high optimization options for irreversible obfuscation
Pyarmor could pack obfuscated scripts into one bundle with PyInstaller
Pyarmor can set expired date for obfuscated scripts. After that, obfuscated scripts can not be run
Pyarmor can bind obfuscated scripts to serial number of harddisk, mac address of network card, ip address etc..
The obfuscated script is black box for end user, add any authentation code in your Python script
The easy way is by pip
pip install pyarmor
Obfuscate script foo.py
and all the other .py
files in the current path, save all the obfuscated scripts to folder dist
pyarmor gen foo.py
Run obfuscated script dist/foo.py
as normal Python script
cd dist
python foo.py
It will start a light weight web server in localhost, and open a page in web browser(snapshots).
pip install pyarmor-webui
pyarmor-webui