PHP uses n-layer encryption eval gzinflate str_rot13 Base64 Hack method Summary

Source: Internet
Author: User
Tags decrypt

PHP uses n-layer encryption eval gzinflate str_rot13 Base64 Hack method SummarySource: This site reprinted anonymous time: 2011-02-14 TAG: I want to contribute
PHP uses eval (gzinflate (str_rot13 (Base64_decode ('BASE64 content after encryption'))) Core code decryption under the non-extensible way of PHP encryption method: Here is an online, not bad. Trojan anti-killing is OK, to protect the code can not be. The corresponding write a simple decryption, specifically for Eval. This principle is very useful. Special Note: This decryption program seems to have to be used above the PHP5, I test the PHP4 above eval (gzinflate (str_rot13 (Base64_decode ('BASE64 content after encryption')), the encrypted code always fails to decrypt properly.<?PHP//file contents that have been encrypted$a ="eval (gzinflate (str_rot13 (Base64_decode (' Put BASE64 Code ' )));"; function decodephp ($a) {$max _level= -;//maximum number of layers for($i =0; $i < $max _level; $i + +) {Ob_start (); eval (Str_replace ('Eval','Echo', $a)); $a=Ob_get_clean ();if(Strpos ($a,'eval (gzinflate (str_rot13 (Base64_decode')===false) { return$a;} }} Echo decodephp ($a);?>PHP uses n-layer encryption eval (gzinflate (Base64_decode ("Codes")) The crack first stated that this is not my original, is I transferred from a foreign blog above. I tested it. If you want to see PHP using eval (gzinflate (str_rot13 (Base64_decode ( 'BASE64 content after encryption'))) The decryption of the core code, please see here: PHP using eval (gzinflate (str_rot13 (Base64_decode ('BASE64 content after encryption'))) The decryption of the core code. Special Note: This decryption program seems to have to be used on the PHP5, I test the PHP4 above eval (gzinflate (Base64_decode ("Codes")), the code that is encrypted is always decrypted as follows:<?PHP/*taken fromhttp://www.php.net/manual/de/function.eval.php#59862Directions: 1. Save this snippet as DECRYPT.PHP2. Save encoded PHP code in CODED.TXT3. Create a blank file called Decoded.txt (from the shell do CHMOD 0666 decoded.txt) 4. Execute This script (visit decrypt.php in a Web browser or does PHP decrypt.php in the shell) 5. Open Decoded.txt, the PHP should is decrypted if not post the code onHttp://www.ariadoss.com/forums/web-development/lampGzinflate The decryption method that executes the encryption code is translated into Chinese text (this paragraph is not in the original file.) 1. Save the entire script as DECRYPT.PHP2. Save the code that needs to be decrypted as Coded.txt and decrypt.php in the same directory. 3. Create a blank file named Decoded.txt (you must set the Decoded.txt permissions to chmod 0666, which is what you can write. Of course, You can not create a file file. As long as the folder has write permissions, the script automatically creates a document named Decoded.txt. ) 4. Run the decryption script (run decrypt.php in the browser to access http://your domain name/storage directory/decrypt.php) 5. Open Decoded.txt, the code should have been decrypted to complete, if an error occurs, send the code toHttp://www.ariadoss.com/forums/web-development/lamp*/Echo"\ndecode nested eval (gzinflate ()) by Debo Jurgen <mailto:[email protected]\n\n"; Echo"1. Reading coded.txt\n"; $fp 1= fopen ("Coded.txt","R"); $contents= Fread ($fp 1, FileSize ("Coded.txt") ); fclose ($fp 1); Echo"2. decoding\n"; while(Preg_match ("/eval\ (gzinflate/", $contents)) {$contents=preg_replace ("/<\?| \?>/","", $contents); Eval (Preg_replace ("/eval/","\ $contents =", $contents)); } Echo"3. Writing decoded.txt\n"; $FP 2 = fopen ("Decoded.txt","W"); Fwrite ($fp 2, Trim ($contents)); Fclose ($fp 2); ?>the Simple Next Gzinflate,eval (Gzinflate (Base64_decode ("Codes")));d ecoding-eval-gzinflate-how to use Base64_decode. Save the above program file decrypt.php, of course the file name can be set by itself. Create a coded.txt in the same directory in this file, which contains the encrypted code, which is the eval (gzinflate (Base64_decode ("Codes")) in the codes; and the point is to decrypt the eval (gzinflate (Base64_decode ("Codes")) . Executes the saved file decrypt.php, which will generate a Decoded.txt txt document in the same directory, opening the document. Inside is the original code that is encrypted.

PHP uses n-layer encryption eval gzinflate str_rot13 Base64 Hack method Summary

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.