mirror of
https://github.com/curl/curl.git
synced 2026-07-23 20:37:16 +03:00
- Introduced a SYST-based test to properly set-up name format when dealing with the OS/400 FTP server.
- Fixed an ftp_readresp() bug preventing detection of failing control socket and causing FTP client to loop forever.
This commit is contained in:
parent
0cb6f3053f
commit
b0b2824b58
6 changed files with 195 additions and 6 deletions
|
|
@ -62,7 +62,7 @@ EXTRA_DIST = test1 test108 test117 test127 test20 test27 test34 test46 \
|
|||
test635 test636 test637 test558 test559 test1086 test1087 test1088 \
|
||||
test1089 test1090 test1091 test1092 test1093 test1094 test1095 test1096 \
|
||||
test1097 test560 test561 test1098 test1099 test562 test563 test1100 \
|
||||
test564 test1101
|
||||
test564 test1101 test1102 test1103
|
||||
|
||||
filecheck:
|
||||
@mkdir test-place; \
|
||||
|
|
|
|||
51
tests/data/test1102
Normal file
51
tests/data/test1102
Normal file
|
|
@ -0,0 +1,51 @@
|
|||
<testcase>
|
||||
<info>
|
||||
<keywords>
|
||||
FTP
|
||||
SYST
|
||||
SITE
|
||||
OS400
|
||||
</keywords>
|
||||
</info>
|
||||
# Server-side
|
||||
<reply>
|
||||
<data nocheck="yes">
|
||||
blabla
|
||||
</data>
|
||||
<servercmd>
|
||||
REPLY PWD 257 "QGPL" is the current library
|
||||
REPLY SYST 215 OS/400 runs this server
|
||||
REPLY SITE 250 Name format set to 1
|
||||
</servercmd>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<server>
|
||||
ftp
|
||||
</server>
|
||||
<name>
|
||||
FTP OS/400 server name format check
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/1102
|
||||
</command>
|
||||
</client>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS ftp@example.com
|
||||
PWD
|
||||
SYST
|
||||
SITE NAMEFMT 1
|
||||
PWD
|
||||
EPSV
|
||||
TYPE I
|
||||
SIZE 1102
|
||||
RETR 1102
|
||||
QUIT
|
||||
</protocol>
|
||||
</verify>
|
||||
</testcase>
|
||||
48
tests/data/test1103
Normal file
48
tests/data/test1103
Normal file
|
|
@ -0,0 +1,48 @@
|
|||
<testcase>
|
||||
<info>
|
||||
<keywords>
|
||||
FTP
|
||||
SYST
|
||||
SITE
|
||||
OS400
|
||||
</keywords>
|
||||
</info>
|
||||
# Server-side
|
||||
<reply>
|
||||
<data nocheck="yes">
|
||||
blabla
|
||||
</data>
|
||||
<servercmd>
|
||||
REPLY PWD 257 "C:/somedir" is the current directory
|
||||
REPLY SYST 215 unknown-OS runs this server
|
||||
</servercmd>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<server>
|
||||
ftp
|
||||
</server>
|
||||
<name>
|
||||
FTP non-OS/400 server
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/1103
|
||||
</command>
|
||||
</client>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS ftp@example.com
|
||||
PWD
|
||||
SYST
|
||||
EPSV
|
||||
TYPE I
|
||||
SIZE 1103
|
||||
RETR 1103
|
||||
QUIT
|
||||
</protocol>
|
||||
</verify>
|
||||
</testcase>
|
||||
Loading…
Add table
Add a link
Reference in a new issue