Skip to main content
added 95 characters in body
Source Link
k_o_
  • 6.5k
  • 1
  • 40
  • 57

Nuitka

I would really recommend Nuitka over Cython. Nuitka also compiles Python to native platform code providing a similar level of obfuscation like compiled C code.

python -m pip install nuitka python -m nuitka --follow-imports --include-package urllib3.util.ssl_ myprogram.py ./myprogram.bin 
  • --follow-imports does a great job of including all imported modules.
  • --include-package if some imports are hidden and are missing when starting the compiled program, it can be helpful to pass additional packages.

Add the flags --onefile or -standalone if this works to get a package for distribution.

I also used pyarmor referenced here, but the pytransform.so or pytransform.dll shared object which is the core of pyarmor is closed source, which was a blocker in my project.

Nuitka

I would really recommend Nuitka over Cython. Nuitka also compiles Python to native platform code providing a similar level of obfuscation like compiled C code.

python -m pip install nuitka python -m nuitka --follow-imports --include-package urllib3.util.ssl_ myprogram.py ./myprogram.bin 
  • --follow-imports does a great job of including all imported modules.
  • --include-package if some imports are hidden and are missing when starting the compiled program, it can be helpful to pass additional packages.

I also used pyarmor referenced here, but the pytransform.so or pytransform.dll shared object which is the core of pyarmor is closed source, which was a blocker in my project.

Nuitka

I would really recommend Nuitka over Cython. Nuitka also compiles Python to native platform code providing a similar level of obfuscation like compiled C code.

python -m pip install nuitka python -m nuitka --follow-imports --include-package urllib3.util.ssl_ myprogram.py ./myprogram.bin 
  • --follow-imports does a great job of including all imported modules.
  • --include-package if some imports are hidden and are missing when starting the compiled program, it can be helpful to pass additional packages.

Add the flags --onefile or -standalone if this works to get a package for distribution.

I also used pyarmor referenced here, but the pytransform.so or pytransform.dll shared object which is the core of pyarmor is closed source, which was a blocker in my project.

Source Link
k_o_
  • 6.5k
  • 1
  • 40
  • 57

Nuitka

I would really recommend Nuitka over Cython. Nuitka also compiles Python to native platform code providing a similar level of obfuscation like compiled C code.

python -m pip install nuitka python -m nuitka --follow-imports --include-package urllib3.util.ssl_ myprogram.py ./myprogram.bin 
  • --follow-imports does a great job of including all imported modules.
  • --include-package if some imports are hidden and are missing when starting the compiled program, it can be helpful to pass additional packages.

I also used pyarmor referenced here, but the pytransform.so or pytransform.dll shared object which is the core of pyarmor is closed source, which was a blocker in my project.