Search code examples
pythonpython-3.xobfuscationpyinstallerdecompiling

Pyminifier (obfuscation) does not appear to change anything other than in command line


I am attempting to obfuscate my python code with pyminifier. Generally I would use SAAS, however it is not within the budget of this small project nor is it feasible to host this as a server application. I have tried the following code:

pyminifier --nonlatin --replacement-length=50 C:/hi.py

Though when I edit the file it does not appear to be any different. The same can be said when I open with Uncompile6. Am I missing something? It changes in command line or appears to. If I distributed this through pyinstaller, the code appears to change in cmd but does not seem any different.


Solution

  • In default, pyminifier only make the file smaller(deleting unnecessary white spaces, comments....). You probably want to run:

    pyminifier -O --nonlatin --replacement-length=50 C:/hi.py