Chronological :
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
You know that there’re a lot of stuff which can encrypted php source
zend,ioncube,etc.., some of these encryptor use some dynamic link library file in they server
to make the encrypted file works, i thought its really waste time :D
coz there’re many ways to make encrypted source, probably the zend,ioncube, or of a kind using dll file just
to make sure none know the algorithm to encrypt the string, and i thought all of this kind use return(eval(theysource)) while the end :P
i mean they probably most used “eval” function at the end :P ( just thought only, no more reason ;P )
i will show you how to make a simple encrypted source code from php algorithm
i will use 3 initiation :D
1. first is variable which contain the encrypted source by base64_encode and a little strtr function
2. second is variable which contain the strrev function ( these just to make the “reader source” a little confuse, and you shouldn’t confuse because these :P )
3. third is variable which contain the eval and encrypted code which will be used to decode the string from the first step
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
here we go
now i would like to make a phpinfo(); code in test.php file
before :
——
phpinfo();
after :
——
$_X='cGhwaW5mbygpOyA=';
$_D=strrev('edoced_46esab');
eval($_D('JF9YPWJhc2U2NF9kZWNvZGUoJF9YKTsgJF9YPXN0cnRyKCRfWCwnIScsJyAnKTskcmVzdWx0PSRfWDtldmFsKCRyZXN1bHQpOyRfWCA9IDA7JHJlc3VsdCA9IDA7'));
how to change like these ??
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
here we go ;
————————————————————-
the string “phpinfo();” has been changed by two operations
1. encoded by base64_encode
2. strtr(base64_encode(”phpinfo();”),’ ‘,’!') // these seems like replace character 1by1 which exact same as it declared
then it changed to : ‘cGhwaW5mbygpOyA=’
————————————————————-
————————————————————-
strrev mean such as reverse the place of character, example : ‘budi’ -> ‘idub’
so you should know now what these used for ;)
————————————————————-
————————————————————-
eval(base64_decode(’JF9YPWJhc2U2NF9kZWNvZGUoJF9YKTsgJF9YPXN0cnRyKCRfWCwnIScsJyAnKTskcmVzdWx0PSRfWDtldmFsKCRyZXN1bHQpOyRfWCA9IDA7JHJlc3VsdCA9IDA7′));
mean there is some code inside after you decode the string
here are the code :
$_X=base64_decode($_X); << first encoding
$_X=strtr($_X,’!',’ ‘); << second encoding
$result = $_X; << declare
eval($result); << run da shitz
$_X = 0; << to make sure that the administrator of your hosting didnt sniff your code easily :D
$result = 0; << idem
————————————————————-
RESULT
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
if the variable $_X contained by ‘cGhwaW5mbygpOyA=’ which mean “phpinfo();” that has been encoded by 2 operation (base64 and strtr), we will see the full of source like these
$_X=’cGhwaW5mbygpOyA=’;
$_X=base64_decode($_X);
$_X=strtr($_X,’!',’ ‘);
$result = $_X;
eval($result);
$_X = 0;
same as like these
$_X=’cGhwaW5mbygpOyA=’;
$_D=strrev(’edoced_46esab’);
eval($_D(’JF9YPWJhc2U2NF9kZWNvZGUoJF9YKTsgJF9YPXN0cnRyKCRfWCwnIScsJyAnKTskcmVzdWx0PSRfWDtldmFsKCRyZXN1bHQpOyRfWCA9IDA7JHJlc3VsdCA9IDA7′));
and also same as like these one :P
phpinfo();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lol, now i hope you got what all these talkin about -_-’,
I just thought that all encryption machine seems like these algorithm but they use C++ to compile and protect they code, and make some changed in placement code,
here i just used the base64 encoding so its very weak, then you could use your strength algorithm to encrypting, and
thanx for all nullers scripts cuz give me idea to wrote these all :D, keep your professional . . . .
if you would like take a look
see these one :
http://h1.ripway.com/tesaja/yukmari1.php
——-
paste your code without < ? and ?> either
test on your localhost
have fun ;)
pusing gw baca nya kalo pake bahasa inggris, capek lah…, keburu males mata gw,…..
learn om :D
stop… aq buka kamus dulu yah
kk ifx ngedate yukkk…. pengin ngedate ama kk
ifx, keep posting. I miss U, ol dong :D
wew,cool
nice article brotha…
it’s great ide for me, can i add your credit to my source?
ehetekeneme
ajarin pls…………….
@bithedz : up2U kk ^^
@irvian : capung de
Hi,
Is there any standard method to protect php source code?
The encoding is a good solution , but please write a complete sample way.
thnx
kevin
@kevin : you should use commercial product such as ioncube, etc . . .
and i’ve been wrote complete sample way of your request above.
;)
omz, pake bahasa jawa aja nape? :D