mirror of
https://github.com/curl/curl.git
synced 2026-01-18 17:21:26 +01:00
ftpserver.pl: fix newlines in 227/229 replies, adjust tests
The test FTP server returned LF newlines for 227/229 replies, instead of the CRLF used for the rest. Test data added later were explicitly made to expect an LF in these response lines. After this patch the FTP server returns CRLF newlines, allowing to delete this special case in test data. Follow-up to3bfff57e1fFollow-up toa7937ed49cCloses #19330
This commit is contained in:
@@ -58,7 +58,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -58,7 +58,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -59,7 +59,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -59,7 +59,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -58,7 +58,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -56,7 +56,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -71,7 +71,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 214
|
||||
150 Binary data connection for %TESTNUMBER () (214 bytes).
|
||||
|
||||
@@ -71,7 +71,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 214
|
||||
150 Binary data connection for %TESTNUMBER () (214 bytes).
|
||||
|
||||
@@ -72,7 +72,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 214
|
||||
150 Binary data connection for %TESTNUMBER () (214 bytes).
|
||||
|
||||
@@ -72,7 +72,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 214
|
||||
150 Binary data connection for %TESTNUMBER () (214 bytes).
|
||||
|
||||
@@ -71,7 +71,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 214
|
||||
150 Binary data connection for %TESTNUMBER () (214 bytes).
|
||||
|
||||
@@ -71,7 +71,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 214
|
||||
150 Binary data connection for %TESTNUMBER () (214 bytes).
|
||||
|
||||
@@ -56,7 +56,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -56,7 +56,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -57,7 +57,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -57,7 +57,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -56,7 +56,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -56,7 +56,7 @@ mooo
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 10
|
||||
150 Binary data connection for %TESTNUMBER () (10 bytes).
|
||||
|
||||
@@ -71,7 +71,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 222
|
||||
150 Binary data connection for %TESTNUMBER () (222 bytes).
|
||||
|
||||
@@ -71,7 +71,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 222
|
||||
150 Binary data connection for %TESTNUMBER () (222 bytes).
|
||||
|
||||
@@ -72,7 +72,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 222
|
||||
150 Binary data connection for %TESTNUMBER () (222 bytes).
|
||||
|
||||
@@ -72,7 +72,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 222
|
||||
150 Binary data connection for %TESTNUMBER () (222 bytes).
|
||||
|
||||
@@ -71,7 +71,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 222
|
||||
150 Binary data connection for %TESTNUMBER () (222 bytes).
|
||||
|
||||
@@ -71,7 +71,7 @@ MOOOO
|
||||
230 Welcome you silly person
|
||||
257 "/" is current directory
|
||||
250 CWD command successful.
|
||||
229 Entering Passive Mode (stripped)
|
||||
229 Entering Passive Mode (stripped)
|
||||
200 I modify TYPE as you wanted
|
||||
213 222
|
||||
150 Binary data connection for %TESTNUMBER () (222 bytes).
|
||||
|
||||
@@ -2566,12 +2566,12 @@ sub PASV_ftp {
|
||||
if($pasvbadip) {
|
||||
$p="1,2,3,4";
|
||||
}
|
||||
sendcontrol sprintf("227 Entering Passive Mode ($p,%d,%d)\n",
|
||||
sendcontrol sprintf("227 Entering Passive Mode ($p,%d,%d)\r\n",
|
||||
int($pasvport/256), int($pasvport%256));
|
||||
}
|
||||
else {
|
||||
# EPSV reply
|
||||
sendcontrol sprintf("229 Entering Passive Mode (|||%d|)\n", $pasvport);
|
||||
sendcontrol sprintf("229 Entering Passive Mode (|||%d|)\r\n", $pasvport);
|
||||
}
|
||||
|
||||
logmsg "Client has been notified that DATA conn ".
|
||||
|
||||
Reference in New Issue
Block a user