hide python code !

Cameron Laird claird at lairds.us
Thu Aug 10 21:46:46 EDT 2006


In article <pan.2006.08.11.00.21.06.658272 at REMOVEME.cybersource.com.au>,
Steven D'Aprano  <steve at REMOVEME.cybersource.com.au> wrote:
>On Thu, 10 Aug 2006 17:03:51 -0700, Bayazee wrote:
>
>> hi
>> in compiled languages when we compile a code to an executable file it
>> convert to a machine code so now we cant access to source ...
>
>There are disassemblers for machine code. If somebody really wants to see
>how your code works, they can do it.
>
>> but in python we easily open the program executable(ascii) file and read
>> source  ....
>
>Yes. That is by design.
>
>> i meen than any way to protect my code or convert it to executable witch
>> can not be decompiled (python code)....
>
>In your first email, you wrote:
>
>"First Iranian Open Source Community : www.python.ir"
>
>Hiding source code is incompatible with Open Source software. You can hide
>code, or be Open Source, but not both.
>
>What makes you think that your code is so special that it is worth
>stealing? Do you have incredible secret algorithms that nobody has ever
>seen before? Or are you just so ashamed of it that you don't want people
>to see it?
>
>Or maybe you've copied other people's code, and you don't want them to see
>that? What are you hiding?
>
>Whatever your reasons for hiding the source code, there are things which
>you can do to obfuscate Python code which will make it difficult for
>people to get to the source code. Google for "python obfuscate" for links.
>But I'm guessing that, if you hide your source code, most people will
>wonder what you are hiding and avoid your program.
>
>If you really want something which compiles to machine code, then Python
>is not the language for you. Use another language. 
			.
			.
			.
Oh, Pyrex <URL:
http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/version/Doc/About.html >
on you.

I'll be more explicit.  If Bayazee or others *truly* want to write in
Python, or something very close to it, and end up with machine code,
there *are* existing techniques, and I recommend Pyrex among them.

I also disagree with your characterization of Open Source.  On the
other hand, your conclusion that Python probably will never make the
we-want-obfuscation-without-much-understanding-of-what-it-is crowd
happy probably is correct.

Myself, I just marvel at the different worlds in which we live.  *My*
experience has to do with how tough it is to deploy and maintain 
correct, working stuff, even with teams of seasoned pros.  The thought
that users will routinely reverse-engineer our applications, and ...
well, I marvel.



More information about the Python-list mailing list