1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
my $so = IO::Socket::INET->new("$host:21") or die $^E;
read2crlf();
$so->print("USER $user".CRLF);
read2crlf();
$so->print("PASS $pass".CRLF);
read2crlf();
$so->print("PASV".CRLF);
read2crlf();
$so->print("CWD files".CRLF);
read2crlf();
$so->print("PWD".CRLF);
read2crlf();
Und der Server antwortet:
220 ProFTPD Server (ProFTPD) [185.146.238.137]
331 Password required for ***
230 User *** logged in
227 Entering Passive Mode (185,146,238,137,202,245).
250 CWD command successful
257 "/files" is the current directory