Advertisement
Guest User

utils.php new reg api added

a guest
Aug 24th, 2016
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.49 KB | None | 0 0
  1. <?php
  2.  
  3. // registration bypass made by Venom, please respect me. // if u use it a first time, it may take like a minute to load because bw servers are slow
  4.  
  5.  
  6. function o2_genhash($info) {
  7. $salt = "P07aJK8soogA815CxjkTcA==";
  8. return md5($salt.$info);
  9. }
  10.  
  11. function md5hash($info) {
  12. return md5($info);
  13. }
  14.  
  15. function timer_getandinc() {
  16. $timer = file_get_contents("timer.txt");
  17. $timer++;
  18. file_put_contents("timer.txt", $timer);
  19. return $timer;
  20. }
  21.  
  22. function moneyexploitLOCID() {
  23. $locid = file_get_contents("locid.txt");
  24. $locid++;
  25. file_put_contents("locid.txt", $locid);
  26. return $locid;
  27. }
  28.  
  29.  
  30. function makevalidsession() {
  31. $userpass = explode(":", file_get_contents("lastaccinfo.txt"));
  32. if(!login($userpass[0], $userpass[1])) {
  33. $newpass = 'random123';
  34. do {
  35. $newuser = 'tech'.rand_string(1, 5); //random word thats valid
  36. } while(!checkuser($newuser));
  37. if(!register($newuser, $newpass))
  38. return false;
  39. else {
  40. file_put_contents("lastaccinfo.txt", $newuser.":".$newpass);
  41. file_put_contents("allaccounts.txt", "[".strftime("%a %m/%d/%Y %I:%M:%S %p")."] - ".$newuser.":".$newpass."\n", FILE_APPEND);
  42. return true;
  43. }
  44. }
  45. return true;
  46. }
  47.  
  48. function login($user, $pass) {
  49. $curl = curl_init("http://lb.binweevils.com/php2/login/logUserIn.php");
  50. curl_setopt($curl, CURLOPT_POST, true);
  51. curl_setopt($curl, CURLOPT_POSTFIELDS, "userID=".$user."&password=".$pass."&rememberMe=1&submitted=1&x=".mt_rand(1, 200)."&y=".mt_rand(1, 100));
  52. curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
  53. curl_setopt($curl, CURLOPT_HEADER, true);
  54. curl_setopt($curl, CURLOPT_COOKIEJAR, "sitecookies.txt");
  55. $header = curl_exec($curl);
  56. curl_close($curl);
  57.  
  58. print($header);
  59.  
  60. if(preg_match('/http:\/\/play\.binweevils.com\?res\=(.*?)\n/', $header))
  61. return false;
  62. return true;
  63. }
  64.  
  65. function rand_string($min, $max) {
  66. $length = mt_rand($min, $max);
  67. $chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
  68. $size = strlen($chars);
  69. for($i = 0; $i < $length; $i++) {
  70. $str .= $chars[mt_rand(0, $size - 1)];
  71. }
  72. return $str;
  73. }
  74.  
  75. function checkuser($user) {
  76. $curl = curl_init("http://play.binweevils.com/ajax/check-username");
  77. curl_setopt($curl, CURLOPT_POST, true);
  78. curl_setopt($curl, CURLOPT_POSTFIELDS, "username=".$user);
  79. curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
  80. $result = json_decode(curl_exec($curl), true);
  81. curl_close($curl);
  82.  
  83. if($result['responseCode'] == 1) // changed to status
  84. return true;
  85. return false;
  86. }
  87.  
  88.  
  89. function register($user, $pass) {
  90. $url = 'http://play.binweevils.com/create-new-weevil';
  91. $formHASH = 'WebKitFormBoundarySUIkNHaMzZZXUURh';
  92. $delimiter = '------'.$formHASH;
  93. $data = '';
  94. $data .= $delimiter."\r\n";
  95. $data .= 'Content-Disposition: form-data; name="username"'. "\r\n\r\n";
  96. $data .= $user. "\r\n";
  97. $data .= $delimiter . "\r\n";
  98. $data .= 'Content-Disposition: form-data; name="password"'. "\r\n\r\n";
  99. $data .= $pass . "\r\n";
  100. $data .= $delimiter . "--\r\n";
  101. $handle = curl_init($url);
  102. curl_setopt($handle, CURLOPT_POST, true);
  103. curl_setopt($handle, CURLOPT_HTTPHEADER , array(
  104. 'Content-Type: multipart/form-data; boundary=----'.$formHASH,
  105. 'Content-Length: ' . strlen($data)));
  106. curl_setopt($handle, CURLOPT_USERAGENT, "Chrome/52.0.2743.116 Safari/537.36");
  107. curl_setopt($handle, CURLOPT_POSTFIELDS, $data);
  108. curl_setopt($handle, CURLOPT_RETURNTRANSFER, 1);
  109. $result = json_decode(curl_exec($handle), true);
  110. curl_close($handle);
  111.  
  112. if($result['status'] == 'ok'){
  113. return true;
  114. print 'works';
  115. } elseif ($result['status'] == 'ko') {
  116. print 'reg error: '.$result['reason'];// val result 2 = username taken// ex = code broken // val 3 = pass or username invalid..
  117. }
  118.  
  119. }
  120.  
  121.  
  122. function getweevilinfo($weevil) {
  123. $curl = curl_init("http://lb.binweevils.com/php2/weevil/getData.php");
  124. curl_setopt($curl, CURLOPT_POST, true);
  125. $timer = timer_getandinc();
  126. $hash = o2_genhash($weevil.$timer);
  127. curl_setopt($curl, CURLOPT_POSTFIELDS, "hash=".$hash."&id=".$weevil."&timer=".$timer);
  128. curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
  129. curl_setopt($curl, CURLOPT_COOKIEFILE, "sitecookies.txt");
  130. $weevildata = json_decode(curl_exec($curl), true);
  131. curl_close($curl);
  132.  
  133. return $weevildata;
  134. }
  135.  
  136.  
  137. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement