new FTP tests
This commit is contained in:
parent
bd8cef5a70
commit
86367d675a
@ -5,9 +5,11 @@ test:
|
||||
[ -f test1 ] || ln -s $(srcdir)/test* .
|
||||
|
||||
EXTRA_DIST = \
|
||||
test1 test104 test11 test15 test20 test23 test33 test6 \
|
||||
test10 test105 test110 test16 test200 test24 test4 test7 \
|
||||
test100 test106 test111 test17 test201 test25 test400 test8 \
|
||||
test101 test107 test12 test18 test202 test26 test43 test9 \
|
||||
test102 test108 test13 test19 test21 test3 test44 \
|
||||
test103 test109 test14 test2 test22 test300 test5
|
||||
test1 test106 test113 test120 test15 test201 test3 test6 \
|
||||
test10 test107 test114 test121 test16 test202 test300 test7 \
|
||||
test100 test108 test115 test122 test17 test21 test33 test8 \
|
||||
test101 test109 test116 test123 test18 test22 test4 test9 \
|
||||
test102 test11 test117 test124 test19 test23 test400 \
|
||||
test103 test110 test118 test125 test2 test24 test43 \
|
||||
test104 test111 test119 test13 test20 test25 test44 \
|
||||
test105 test112 test12 test14 test200 test26 test5
|
||||
|
37
tests/data/test112
Normal file
37
tests/data/test112
Normal file
@ -0,0 +1,37 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP PASV upload resume
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/112 -T log/upload112 -C 40
|
||||
</command>
|
||||
<file name="log/upload112">
|
||||
this is the *****crap******** that we're gonna upload
|
||||
|
||||
worx?
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<strip>
|
||||
</strip>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
PASV
|
||||
TYPE I
|
||||
APPE 112
|
||||
</protocol>
|
||||
<upload>
|
||||
gonna upload
|
||||
|
||||
worx?
|
||||
</upload>
|
||||
</verify>
|
26
tests/data/test113
Normal file
26
tests/data/test113
Normal file
@ -0,0 +1,26 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP download, failed login: USER not valid
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/113
|
||||
</command>
|
||||
<file name="log/ftpserver.cmd">
|
||||
REPLY USER 314 bluah you fewl!
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<errorcode>
|
||||
12
|
||||
</errorcode>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
</protocol>
|
||||
</verify>
|
27
tests/data/test114
Normal file
27
tests/data/test114
Normal file
@ -0,0 +1,27 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP download, failed login: PASS not valid
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/114
|
||||
</command>
|
||||
<file name="log/ftpserver.cmd">
|
||||
REPLY PASS 314 bluah you f00l!
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<errorcode>
|
||||
11
|
||||
</errorcode>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
</protocol>
|
||||
</verify>
|
29
tests/data/test115
Normal file
29
tests/data/test115
Normal file
@ -0,0 +1,29 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP download, failed PASV
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/115
|
||||
</command>
|
||||
<file name="log/ftpserver.cmd">
|
||||
REPLY PASV 314 bluah you f00l!
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<errorcode>
|
||||
13
|
||||
</errorcode>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
PASV
|
||||
</protocol>
|
||||
</verify>
|
31
tests/data/test116
Normal file
31
tests/data/test116
Normal file
@ -0,0 +1,31 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP download, failed PORT
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/116 -P 127.0.0.1
|
||||
</command>
|
||||
<file name="log/ftpserver.cmd">
|
||||
REPLY PORT 314 bluah you f00l!
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<errorcode>
|
||||
30
|
||||
</errorcode>
|
||||
<strip>
|
||||
^PORT 127,0,0,1,.*
|
||||
</strip>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
</protocol>
|
||||
</verify>
|
30
tests/data/test117
Normal file
30
tests/data/test117
Normal file
@ -0,0 +1,30 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP download, failed TYPE
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/117
|
||||
</command>
|
||||
<file name="log/ftpserver.cmd">
|
||||
REPLY TYPE 314 bluah you f00l!
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<errorcode>
|
||||
17
|
||||
</errorcode>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
PASV
|
||||
TYPE I
|
||||
</protocol>
|
||||
</verify>
|
31
tests/data/test118
Normal file
31
tests/data/test118
Normal file
@ -0,0 +1,31 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP download, failed RETR
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/118
|
||||
</command>
|
||||
<file name="log/ftpserver.cmd">
|
||||
REPLY RETR 314 bluah you f00l!
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<errorcode>
|
||||
19
|
||||
</errorcode>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
PASV
|
||||
TYPE I
|
||||
RETR 118
|
||||
</protocol>
|
||||
</verify>
|
33
tests/data/test119
Normal file
33
tests/data/test119
Normal file
@ -0,0 +1,33 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP download, failed RETR with PORT
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/119 -P -
|
||||
</command>
|
||||
<file name="log/ftpserver.cmd">
|
||||
REPLY RETR 314 bluah you f00l!
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<errorcode>
|
||||
19
|
||||
</errorcode>
|
||||
<strip>
|
||||
^PORT.*
|
||||
</strip>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
TYPE I
|
||||
RETR 119
|
||||
</protocol>
|
||||
</verify>
|
34
tests/data/test120
Normal file
34
tests/data/test120
Normal file
@ -0,0 +1,34 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
<data>
|
||||
data
|
||||
to
|
||||
see
|
||||
that FTP
|
||||
works
|
||||
so does it?
|
||||
</data>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
ftp download with post-quote delete operation
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/120 -Q "-DELE file"
|
||||
</command>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
PASV
|
||||
TYPE I
|
||||
RETR 120
|
||||
DELE file
|
||||
</protocol>
|
||||
</verify>
|
35
tests/data/test121
Normal file
35
tests/data/test121
Normal file
@ -0,0 +1,35 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
<data>
|
||||
data
|
||||
to
|
||||
see
|
||||
that FTP
|
||||
works
|
||||
so does it?
|
||||
</data>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
ftp download with post- and pre-transfer delete operations
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/121 -Q "-DELE after_transfer" -Q "DELE before_transfer"
|
||||
</command>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
DELE before_transfer
|
||||
PASV
|
||||
TYPE I
|
||||
RETR 121
|
||||
DELE after_transfer
|
||||
</protocol>
|
||||
</verify>
|
28
tests/data/test122
Normal file
28
tests/data/test122
Normal file
@ -0,0 +1,28 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
<size>
|
||||
5
|
||||
</size>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP download resume with whole file already downloaded
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/122 -C 5
|
||||
</command>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
PASV
|
||||
TYPE I
|
||||
SIZE 122
|
||||
</protocol>
|
||||
</verify>
|
27
tests/data/test123
Normal file
27
tests/data/test123
Normal file
@ -0,0 +1,27 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP upload resume with whole file already downloaded
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/123 -T log/upload123 -C 51
|
||||
</command>
|
||||
<file name="log/upload123">
|
||||
--------------------------------------------------
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
PASV
|
||||
TYPE I
|
||||
</protocol>
|
||||
</verify>
|
31
tests/data/test124
Normal file
31
tests/data/test124
Normal file
@ -0,0 +1,31 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
<data>
|
||||
we can still send data even if pwd fails!
|
||||
</data>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP download, failed PWD
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/124
|
||||
</command>
|
||||
<file name="log/ftpserver.cmd">
|
||||
REPLY PWD 314 bluah you f00l!
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
PASV
|
||||
TYPE I
|
||||
RETR 124
|
||||
</protocol>
|
||||
</verify>
|
29
tests/data/test125
Normal file
29
tests/data/test125
Normal file
@ -0,0 +1,29 @@
|
||||
# Server-side
|
||||
<reply>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<name>
|
||||
FTP download, failed CWD
|
||||
</name>
|
||||
<command>
|
||||
ftp://%HOSTIP:%FTPPORT/path/to/file/125
|
||||
</command>
|
||||
<file name="log/ftpserver.cmd">
|
||||
REPLY CWD 314 bluah you f00l!
|
||||
</file>
|
||||
</test>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<errorcode>
|
||||
9
|
||||
</errorcode>
|
||||
<protocol>
|
||||
USER anonymous
|
||||
PASS curl_by_daniel@haxx.se
|
||||
PWD
|
||||
CWD path/to/file
|
||||
</protocol>
|
||||
</verify>
|
Loading…
x
Reference in New Issue
Block a user