V
V
VictimAlex2011-09-20 09:26:40
PHP
VictimAlex, 2011-09-20 09:26:40

How to protect php code from theft. What and how to encode?

I have scripts of my own design. It’s so customary in the Russian Internet to remove copyrights, or even to appropriate someone else’s to yourself and even sell it :( How can

you protect your code from such changes.

options, please, gentlemen experts.

Answer the question

In order to leave comments, you need to log in

11 answer(s)
A
AFoST, 2011-09-20
@AFoST

Possibly ioncube www.ioncube.com

A
Alexey, 2011-09-20
@alexxxst

If someone needs it, he will decipher it.

G
gro, 2011-09-20
@gro

Make it public with your own copyrights.

C
cat_crash, 2011-09-20
@cat_crash

Nothing. Zend, Ioncube, etc. It's more foolproof.
In view of the implementation features, languages ​​such as .net, Java, JS cannot be protected, because they are executed not directly by the processor but in the virtual machine.
As an option, it is impossible to obussify the code to. Thus, you will make it practically unreadable, hard to change, but absolutely working.
But for good - if you are afraid for your unique development ... and it is truly unique and so in demand - you need to sell it according to the SaaS principle

S
svetko, 2012-04-06
@svetko

guys, you'll put at least a million bucks into protection and obfuscation.
but all of it will be done with 5 lines of code:
wrapper.php
<?php
ob_start();
require('megaprivatesuperscript.php');
$content = ob_get_contents();
ob_end_clean();
echo str_replace(' copyright ', 'Mega Free Script', $content);

M
mihavxc, 2011-09-20
@mihavxc

Move part of the functionality to an external library :)

F
Fastto, 2011-09-20
@Fastto

first option - write your own obfuscator - the effect will be better, if you want an example, knock on the PM
second option - move part of the code to the php extension - for example, rendering certain widgets, in general, according to the situation, the
third option - encoding the interpreted code, decoding is done by the functions of the php extension, at the same time, the encoded code was also obfuscated before that, as well as part of the application logic was taken out by separate classes / functions in the extension. Not a panacea, but 95% of those who want to hack will be cut off, and those who really need to get your code will get it anyway.

D
Denis Turenko, 2011-09-20
@Dennion

Try truebug www.truebug.com

A
alesto, 2011-09-20
@alesto

What script did you write? Are you sure that it is your script that is used on sites without copyrights?
zend guard has the ability to obsfucate.

A
a_dobkin, 2011-09-21
@a_dobkin

Alternatively, the code that needs to be protected, for example, any algorithms, can be moved to a dynamic PHP extension, rewriting this code in C accordingly.
This, of course, will require more effort and time, but it is much more reliable than using zend guard, ioncube or obfuscators

F
fack, 2014-08-19
@fack

<?php
ob_start();
require('megaprivatesuperscript.php');
$content = ob_get_contents();
ob_end_clean();
echo str_replace('copyright', 'Mega Free Script', $content);
This code will not work if I set permissions on the folder in Linux - only to run.
A bit late :)))
Linux drags the boys!!!!!!!!!!!!!1

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question