mirror of
https://github.com/Ponce/slackbuilds
synced 2024-12-01 01:00:03 +01:00
19 lines
406 B
Perl
19 lines
406 B
Perl
|
#!/usr/bin/perl
|
||
|
|
||
|
# test.pl: small script to test mod_dosevasive's effectiveness
|
||
|
|
||
|
use IO::Socket;
|
||
|
use strict;
|
||
|
|
||
|
for(0..100) {
|
||
|
my($response);
|
||
|
my($SOCKET) = new IO::Socket::INET( Proto => "tcp",
|
||
|
PeerAddr=> "127.0.0.1:80");
|
||
|
if (! defined $SOCKET) { die $!; }
|
||
|
print $SOCKET "GET /?$_ HTTP/1.0\n\n";
|
||
|
$response = <$SOCKET>;
|
||
|
print $response;
|
||
|
close($SOCKET);
|
||
|
}
|
||
|
|