make the ftp server support reply/servercmd, and make SLOWDOWN work, and

update the docs accordingly
This commit is contained in:
Daniel Stenberg
2005-04-14 22:52:08 +00:00
parent e9d068b913
commit cd1144dc24
3 changed files with 19 additions and 10 deletions

View File

@@ -118,7 +118,7 @@ sub sendcontrol {
for(@a) {
print $_;
select(undef, undef, undef, 0.1);
select(undef, undef, undef, 0.02);
}
}
@@ -544,6 +544,7 @@ sub customize {
undef %customreply;
$nosave = 0; # default is to save as normal
$controldelay = 0; # default is no delaying the responses
open(CUSTOM, "<log/ftpserver.cmd") ||
return 1;
@@ -565,6 +566,10 @@ sub customize {
$delayreply{$1}=$2;
logmsg "FTPD: delay reply for $1 with $2 seconds\n";
}
elsif($_ =~ /SLOWDOWN/) {
$controldelay=1;
logmsg "FTPD: send response with 0.1 sec delay between each byte\n";
}
elsif($_ =~ /RETRWEIRDO/) {
logmsg "FTPD: instructed to use RETRWEIRDO\n";
$retrweirdo=1;