http://pecl.php.net/package/bcompilerhttp://pecl.php.net/package/bcompiler wrote:bcompiler enables you to encode your scripts in phpbytecode, enabling you to protect the source code.
bcompiler could be used in the following situations
- to create a exe file of a PHP-GTK application (in conjunction with other software)
- to create closed source libraries
- to provide clients with time expired software (prior to payment)
- to deliver close source applications
- for use on embedded systems, where disk space is a priority.
Protecting your PHP source-code
Moderator: General Moderators
Protecting your PHP source-code
For those of us who use PHP commercially and sell their applications, this is very nice indeed.
- llanitedave
- Forum Commoner
- Posts: 78
- Joined: Thu Jan 15, 2004 11:24 am
- Location: Las Vegas, NV.
This gives me a chance to ask for some clarifications about the GPL or about the PHP license, which I must admit to not having a real good understanding of.
Does the GPL'd language allow you to create proprietary (closed source) works using that language? Does the PHP license differ from the GPL in that respect, or is that an interpretation of open-source licenses in general?
Does the GPL'd language allow you to create proprietary (closed source) works using that language? Does the PHP license differ from the GPL in that respect, or is that an interpretation of open-source licenses in general?
No. If you modify a php app distributed under GPL, the licence also applies to your modified version. This means developments are fed back into the community.llanitedave wrote:Does the GPL'd language allow you to create proprietary (closed source) works using that language?
BSD does not impose this restriction.
- llanitedave
- Forum Commoner
- Posts: 78
- Joined: Thu Jan 15, 2004 11:24 am
- Location: Las Vegas, NV.
-
ilovetoast
- Forum Contributor
- Posts: 142
- Joined: Thu Jan 15, 2004 7:34 pm
Don't mean to be contrary but I'll add one caveat to McGruff.
He's right in that if "modify a php app distributed under GPL, the licence also applies to your modified version." The key word there is app. You can't take someone elses source code for a PHP app that is distributed via GPL and put it into a non-GPL project. For example, you can't take a database abstraction set of classes that is GPL'd and incorporate it into your non-GPL'd database abstraction commercial product.
You can howver use the PHP language to develop an application that is not GPL'd. You can develop a PHP application that is intended to work with MySQL and have that application be non-GPL'd as well. You cannot distribute the MySQL source or binaries with that app in that case. You cannot distribute the PHP source or binaries either in that case.
Easy example - Linux is GPL. I can write a commercial program to run on Linux. I cannot distribute Linux as a part of that commercial program.
My suggestion if you need PHP + db is:
1) Write in PHP without fear, just require that the end user have PHP etc. properly installed and running.
2) Drop MySQL. It is a pig anyways.
3) Use SQLite instead. You can distibute the SQLite code with/inside your app, as it's not GPL. Plus in PHP 5 it will be enabled by default.
He's right in that if "modify a php app distributed under GPL, the licence also applies to your modified version." The key word there is app. You can't take someone elses source code for a PHP app that is distributed via GPL and put it into a non-GPL project. For example, you can't take a database abstraction set of classes that is GPL'd and incorporate it into your non-GPL'd database abstraction commercial product.
You can howver use the PHP language to develop an application that is not GPL'd. You can develop a PHP application that is intended to work with MySQL and have that application be non-GPL'd as well. You cannot distribute the MySQL source or binaries with that app in that case. You cannot distribute the PHP source or binaries either in that case.
Easy example - Linux is GPL. I can write a commercial program to run on Linux. I cannot distribute Linux as a part of that commercial program.
My suggestion if you need PHP + db is:
1) Write in PHP without fear, just require that the end user have PHP etc. properly installed and running.
2) Drop MySQL. It is a pig anyways.
3) Use SQLite instead. You can distibute the SQLite code with/inside your app, as it's not GPL. Plus in PHP 5 it will be enabled by default.
-
ilovetoast
- Forum Contributor
- Posts: 142
- Joined: Thu Jan 15, 2004 7:34 pm
One more thing. bcompiler gives the illusion of security. It is one step more than simple obfuscation techniques, but not a very big one. Decompiling PHP byte code is easy enough for those who know what to do.
I think it's a great idea if that's what you need, I just don't like the way it is described. They toss around words like "compiled" and "bytecode" to give the impression to prospective (and less knowledgeable in PHP nuts and bolts) users that it is something analogous to compiled C/C++. It is not.
My nit is with the implications of their description. Implications that I feel intentionally overstate and potentially mislead.
I think it's a great idea if that's what you need, I just don't like the way it is described. They toss around words like "compiled" and "bytecode" to give the impression to prospective (and less knowledgeable in PHP nuts and bolts) users that it is something analogous to compiled C/C++. It is not.
My nit is with the implications of their description. Implications that I feel intentionally overstate and potentially mislead.
-
ilovetoast
- Forum Contributor
- Posts: 142
- Joined: Thu Jan 15, 2004 7:34 pm