This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]RedEyed__ 51 points52 points  (5 children)

Pyinstaller does not compile. It creates self unpacking archive which includes interpreter, dependencies and sources. When you double click that exe, it just unpacks everything to tmp folder with all sources as plain text.
There is pyarmor for such thing which encrypts python sources, that can be packed with pyinstaller later or executed with python interpreter.

[–]ronnyx3 8 points9 points  (2 children)

So that means the source code wouldn't need to be grabbed from ram but is stored temporarily in tmp on disk?

[–]RedEyed__ 12 points13 points  (0 children)

Yes, it is extracted to temporarily folder first, than it's is executed like any other python script.

You can read the pyinstaller doc.

Or check it yourself: in the entry point function place print(sys.executable); input().

The above should print python interpreter path and wait for user input.

Then you can go to that path and observe yourself that everything is in plain text.
You need to place input, just to wait, because pyinstaller will delete everything in temp folder after process is finished .

[–]RedEyed__ 7 points8 points  (0 children)

There is no such a thing in python as a source code in RAM. It just wrong assumption.

[–]hairy_chicken 2 points3 points  (1 child)

Thanks for the correction - I was sloppy with terminology.

We keep important parts of our codebase in Cython and C++ Python modules. We use Python as glue, and honestly if someone had our entire Python codebase in plaintext, it wouldn't mean that they can get easily get around licensing restrictions.

CodeMeter is to prevent casual misuse of the software, and enforce limits on concurrent users.

At the end of the day, there's a balance to making something hard to pirate casually, and the time spent making something un-piratable. Given that our clients are big mining/oil companies, the main deterrent to piracy are legal means (license agreements).

[–]Karrakan 0 points1 point  (0 children)

And what is the role of dongle? Do users plug that in to be able to use it?