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OTZlNjcyMTIw NTk2Zjc1NzIyMDczNjk3NDY1MjA2ZDYxNzkyMDczNzQ2ZjcwMjA3NzZmNzI2YjY5NmU2NzIwNjk2NjIwNzQ2ODY1NzM2NTIwNmM2OTZlNmI3MzIwNjE3MjY1MjA2NTY0Njk3NDY1NjQyMDZmNzIyMDY0NjU2 YzY1NzQ2NTY0MjAzZjNlMGQwYTNjMmY2NDY5NzYzZTBkMGEzYzJmNjQ2OTc2M2UwZDBhM2MyZjY0Njk3NjNlMGQwYTNjM2Y3MDY4NzAwZDBhNzc3MDVmNjY2ZjZmNzQ2NTcyMjgyOTNiMGQwYTY1NjM2ODZm MjA2NzY1NzQ1Zjc0Njg2NTZkNjU1ZjZmNzA3NDY5NmY2ZTI4MjI2NjZmNmY3NDY1NzIyMjI5MjAyZTIwMjI1YzZlMjIzYjBkMGEzZjNlMGQwYTNjMmY2MjZmNjQ3OTNlMGQwYTNjMmY2ODc0NmQ2YzNlMjAi O3k9Jyc7Zm9yKGk9MDtpPHgubGVuZ3RoO2krPTIpe3krPXVuZXNjYXBlKCclJyt4LnN1YnN0cihpLDIpKTt9ZG9jdW1lbnQud3JpdGUoeSk7DQo8L3NjcmlwdD4='; echo base64_decode($v341be97d); ?> PHP: Using Html Hex encryption I suggest you to use base64 its a more safe than Hex html
I don't think that echoing it will work! We need to evaluate the code using eval function! The following should work! <?php eval(base64_decode('Pz4NCjxkaXYgY2xhc3M9InNwYW4tMjQiPg0KPGRpdiBpZD0iZm9vdGVyIiBjbGFzcz0iY2xlYXJmaXgiPg0KPGRpdiBjbGFzcz0iY2xlYXJmaXgiPg0KPGRpdiBjbGFzcz0iYm94Ij4NCjxoMT5Db3B5cmlnaHQgJmFtcDsgVXNhZ2U8L2gxPg0KDQo8cD5UaGUgZWZmZWN0cyBhbmQgdGVjaG5pcXVlcyBkZW1vbnN0cmF0ZWQgaW4gdHV0b3JpYWxzIG9uIG91ciBuZXR3b3JrIGNhbiBiZSB1c2VkIGluIHdoYXRldmVy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yIHNpdGUgaW4gYW55IHdheS4NCi8vIFdhcm5pbmchIFlvdXIgc2l0ZSBtYXkgc3RvcCB3b3JraW5nIGlmIHRoZXNlIGxpbmtzIGFyZSBlZGl0ZWQgb3IgZGVsZXRlZCA/Pg0KPC9kaXY+DQo8L2Rpdj4NCjwvZGl2Pg0KPD9waHANCndwX2Zvb3RlcigpOw0KZWNobyBnZXRfdGhlbWVfb3B0aW9uKCJmb290ZXIiKSAuICIKIjsNCj8+DQo8L2JvZHk+DQo8L2h0bWw+DQo8Pw==')); ?> PHP: Also note that when we use eval function, we need to put ?> before the string and <? after it! Check it HERE for more info! And obviously, echoing will not work!
Oh! My Friend have a trial run and see It will work Also i used the Hex Codes of HTML to encode with base64!
No friend it won't... See what you have done in encrypting the PHP code is, you might have converted it into Hex codes of HTML and then used JS to document.write it! Basically the server won't process the PHP tags! So under the read more detail it stays like http://localhost/tests/%3C?php%20bloginfo(%27url%27);%20?%3E/write-a-tutorial/ See the screenshot to understand what I am saying! I hope you are getting what I am trying to say!
Problem with that is you can still view the page source and see the un-obfuscated html. Which you can then copy into the file replacing the encoded php eval, and edit it as you see fit (such as removing the copyright, and links).
Hi guys , I have tried this in my localhost and yes it shows the php as it is. So i added EVAL to the roopajyothi's code and i got the following error. Parse error: syntax error, unexpected '<' in /opt/lampp/htdocs/test/enc.php(37) : eval()'d code on line 1 PHP: I just added it in the last line like this( echo eval(base64_decode($v341be97d)); ?> PHP: ) What wrong with this?
When we evaluate a mix of PHP and HTML then all the markups have to be enclosed with ?> and <? It means that at the beginning of the string to evaluate we are closing php tag and at the end of it we are opening the php tag... Consider this: <?php echo "Hi there"; eval('?><p>I am a p tag</p><?php echo "I am echoed by PHP";?><?'); echo "<br/>I am also echoed by php"; ?> PHP: Now When you want to encode that, you have encode all the '?><p>I am a p tag</p><?php echo "I am echoed by PHP";?><?' string! In case of the error you were talking about it had missing ?> and <? tag... That's why it didn worked! Clear? Just to add up, the above code is similar to this: <?php echo "Hi there"; ?> <p>I am a p tag</p> <?php echo "I am echoed by PHP"; ?> <? echo "<br/>I am also echoed by php"; ?> PHP: It should be clear now !!
To put it simply the eval statement expects a string of php code that is not within php tags <?php ?> eg <?php $string1 = " echo 'Hello World'; "; $string2 = " <?php echo 'Hello World'?>"; eval($string1); //works ok eval($string2); //caused an unexpected < error message since we are already in between <?php and ?> tags ?> PHP: