Note that objdump makes a pretty good disassembly of a C binary.mmkw43 wrote: ↑Fri May 14, 2021 2:11 pmWhat are the basics of Cython in a few words? I know nothing about it other than some simple statements I read about "converting python to c" (although I'm sure it's not that simple) Does it offer more protection or worth learning about?
And to answer, the one project has about 3K lines but much of it is repetition because it's an 8 channel device and it also uses tkinter.
I actually (for the fun of it) may delve into C -- I did before briefly but got distracted.
The main strategy I know to keep a third party from looking at a program is to run the code in the cloud. Such things require always-on networking and are subject to network disruptions; however, advances in technology and strong cryptography have made the cloud approach more reliable and less risky over time. It's very popular with mobile phone applications.
Another approach is to make sure your customers agree in writing not to peek at the computer program you supply. This has the drawback--as in the ice-cream maker scandal--that a third party might steal the software from your customer and then peek without having signed the contract. How enforceable such contacts are in the first place is also difficult to ascertain.
Another point of view is that you actually want customers to peek at the program, fix the bugs they find and send the corrections back to you. This is the model under which Linux is distributed and it seems to have been successful.
My feeling is tools available to obscure Python source code are sufficient and C doesn't provide much better protection. One thing I would suggest would be to place a few Easter eggs in the code--some obscure undocumented features mixed in with everything else--that can be used to distinguish whether someone copied your code or engaged in legitimate clean-room reverse engineering practices when creating a look alike. A common example of such an Easter egg would be code that mysteriously prints out your name using a compressed mathematical formula that can be mixed in unobserved with the rest of the program without anyone noticing.