From cabb46db3ddfa9ed609cc805618401ac0ec3a918 Mon Sep 17 00:00:00 2001
From: Daniel Stenberg <daniel@haxx.se>
Date: Wed, 28 Nov 2001 13:45:50 +0000
Subject: [PATCH] adjusted to new FTP commands in the command sequence

---
 tests/data/test103 | 1 +
 tests/data/test105 | 6 ++++++
 tests/data/test106 | 3 ++-
 tests/data/test107 | 2 +-
 tests/data/test109 | 2 +-
 tests/data/test110 | 4 ++++
 tests/data/test111 | 2 +-
 tests/data/test112 | 2 +-
 tests/data/test115 | 2 ++
 tests/data/test117 | 2 ++
 tests/data/test118 | 3 +++
 tests/data/test119 | 1 +
 tests/data/test120 | 5 +++++
 tests/data/test121 | 3 ++-
 tests/data/test122 | 4 ++++
 tests/data/test123 | 2 +-
 tests/data/test124 | 3 +++
 tests/data/test400 | 4 ++++
 18 files changed, 44 insertions(+), 7 deletions(-)

diff --git a/tests/data/test103 b/tests/data/test103
index 23df6df9ff..224e32a9ed 100644
--- a/tests/data/test103
+++ b/tests/data/test103
@@ -34,6 +34,7 @@ PWD
 CWD a/path
 PORT 127,0,0,1,246,33
 TYPE I
+SIZE 103
 RETR 103
 </protocol>
 </verify>
diff --git a/tests/data/test105 b/tests/data/test105
index 3cecc296c9..3ae69d4e59 100644
--- a/tests/data/test105
+++ b/tests/data/test105
@@ -18,6 +18,10 @@ FTP user+password in URL and ASCII transfer
  <command>
 ftp://userdude:passfellow@%HOSTIP:%FTPPORT/103 --use-ascii
 </command>
+<file name="log/ftpserver.cmd">
+REPLY EPSV 500 no such command
+REPLY SIZE 500 no such command
+</file>
 </test>
 
 # Verify data after the test has been "shot"
@@ -26,8 +30,10 @@ ftp://userdude:passfellow@%HOSTIP:%FTPPORT/103 --use-ascii
 USER userdude
 PASS passfellow
 PWD
+EPSV
 PASV
 TYPE A
+SIZE 103
 RETR 103
 </protocol>
 </verify>
diff --git a/tests/data/test106 b/tests/data/test106
index 61c43b8f69..fdf6cb019b 100644
--- a/tests/data/test106
+++ b/tests/data/test106
@@ -27,8 +27,9 @@ USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
 CWD /path with  spaces/and things2
-PASV
+EPSV
 TYPE A
+SIZE 106
 RETR 106
 </protocol>
 </verify>
diff --git a/tests/data/test107 b/tests/data/test107
index 98fa773ad7..ebbeefee98 100644
--- a/tests/data/test107
+++ b/tests/data/test107
@@ -31,7 +31,7 @@ works
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
-PASV
+EPSV
 TYPE I
 STOR 107
 </protocol>
diff --git a/tests/data/test109 b/tests/data/test109
index 18661885d5..a109c62c00 100644
--- a/tests/data/test109
+++ b/tests/data/test109
@@ -26,7 +26,7 @@ Moooooooooooo
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
-PASV
+EPSV
 TYPE I
 APPE 109
 </protocol>
diff --git a/tests/data/test110 b/tests/data/test110
index ce0df48d3e..310517468a 100644
--- a/tests/data/test110
+++ b/tests/data/test110
@@ -17,6 +17,9 @@ FTP download resume with set limit
  <command>
 ftp://%HOSTIP:%FTPPORT/110 -C 20
 </command>
+<file name="log/ftpserver.cmd">
+REPLY EPSV 500 no such command
+</file>
 </test>
 
 # Verify data after the test has been "shot"
@@ -27,6 +30,7 @@ ftp://%HOSTIP:%FTPPORT/110 -C 20
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
+EPSV
 PASV
 TYPE I
 SIZE 110
diff --git a/tests/data/test111 b/tests/data/test111
index 6201f34940..8e80ecb620 100644
--- a/tests/data/test111
+++ b/tests/data/test111
@@ -26,7 +26,7 @@ ftp://%HOSTIP:%FTPPORT/111 -C 2000
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
-PASV
+EPSV
 TYPE I
 SIZE 111
 </protocol>
diff --git a/tests/data/test112 b/tests/data/test112
index 712a16cec4..b551522428 100644
--- a/tests/data/test112
+++ b/tests/data/test112
@@ -25,7 +25,7 @@ worx?
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
-PASV
+EPSV
 TYPE I
 APPE 112
 </protocol>
diff --git a/tests/data/test115 b/tests/data/test115
index a480f91179..73ee731f21 100644
--- a/tests/data/test115
+++ b/tests/data/test115
@@ -12,6 +12,7 @@ ftp://%HOSTIP:%FTPPORT/115
 </command>
 <file name="log/ftpserver.cmd">
 REPLY PASV 314 bluah you f00l!
+REPLY EPSV 314 bluah you f00l!
 </file>
 </test>
 
@@ -24,6 +25,7 @@ REPLY PASV 314 bluah you f00l!
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
+EPSV
 PASV
 </protocol>
 </verify>
diff --git a/tests/data/test117 b/tests/data/test117
index 617fc9149f..edd5b7e09f 100644
--- a/tests/data/test117
+++ b/tests/data/test117
@@ -11,6 +11,7 @@ FTP download, failed TYPE
 ftp://%HOSTIP:%FTPPORT/117
 </command>
 <file name="log/ftpserver.cmd">
+REPLY EPSV 314 bluah you f00l!
 REPLY TYPE 314 bluah you f00l!
 </file>
 </test>
@@ -24,6 +25,7 @@ REPLY TYPE 314 bluah you f00l!
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
+EPSV
 PASV
 TYPE I
 </protocol>
diff --git a/tests/data/test118 b/tests/data/test118
index 42dca01dbe..ffd3e0130c 100644
--- a/tests/data/test118
+++ b/tests/data/test118
@@ -12,6 +12,7 @@ ftp://%HOSTIP:%FTPPORT/118
 </command>
 <file name="log/ftpserver.cmd">
 REPLY RETR 314 bluah you f00l!
+REPLY EPSV 314 bluah you f00l!
 </file>
 </test>
 
@@ -24,8 +25,10 @@ REPLY RETR 314 bluah you f00l!
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
+EPSV
 PASV
 TYPE I
+SIZE 118
 RETR 118
 </protocol>
 </verify>
diff --git a/tests/data/test119 b/tests/data/test119
index 9ba070e54e..4aa681482c 100644
--- a/tests/data/test119
+++ b/tests/data/test119
@@ -30,6 +30,7 @@ USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
 TYPE I
+SIZE 119
 RETR 119
 </protocol>
 </verify>
diff --git a/tests/data/test120 b/tests/data/test120
index 095d03bd1d..bb97eff4a9 100644
--- a/tests/data/test120
+++ b/tests/data/test120
@@ -18,6 +18,9 @@ ftp download with post-quote delete operation
  <command>
 ftp://%HOSTIP:%FTPPORT/120 -Q "-DELE file"
 </command>
+<file name="log/ftpserver.cmd">
+REPLY EPSV 314 bluah you f00l!
+</file>
 </test>
 
 # Verify data after the test has been "shot"
@@ -26,8 +29,10 @@ ftp://%HOSTIP:%FTPPORT/120 -Q "-DELE file"
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
+EPSV
 PASV
 TYPE I
+SIZE 120
 RETR 120
 DELE file
 </protocol>
diff --git a/tests/data/test121 b/tests/data/test121
index 3ac985c6aa..c94b6262f0 100644
--- a/tests/data/test121
+++ b/tests/data/test121
@@ -27,8 +27,9 @@ USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
 DELE before_transfer
-PASV
+EPSV
 TYPE I
+SIZE 121
 RETR 121
 DELE after_transfer
 </protocol>
diff --git a/tests/data/test122 b/tests/data/test122
index b9990d9822..f1a481b1ba 100644
--- a/tests/data/test122
+++ b/tests/data/test122
@@ -13,6 +13,9 @@ FTP download resume with whole file already downloaded
  <command>
 ftp://%HOSTIP:%FTPPORT/122 -C 5
 </command>
+<file name="log/ftpserver.cmd">
+REPLY EPSV 500 no such command
+</file>
 </test>
 
 # Verify data after the test has been "shot"
@@ -21,6 +24,7 @@ ftp://%HOSTIP:%FTPPORT/122 -C 5
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
+EPSV
 PASV
 TYPE I
 SIZE 122
diff --git a/tests/data/test123 b/tests/data/test123
index c2e81646c5..218548aa70 100644
--- a/tests/data/test123
+++ b/tests/data/test123
@@ -21,7 +21,7 @@ ftp://%HOSTIP:%FTPPORT/123 -T log/upload123 -C 51
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
-PASV
+EPSV
 TYPE I
 </protocol>
 </verify>
diff --git a/tests/data/test124 b/tests/data/test124
index 106291fd46..6ae97b7802 100644
--- a/tests/data/test124
+++ b/tests/data/test124
@@ -15,6 +15,7 @@ ftp://%HOSTIP:%FTPPORT/124
 </command>
 <file name="log/ftpserver.cmd">
 REPLY PWD 314 bluah you f00l!
+REPLY EPSV 314 bluah you f00l!
 </file>
 </test>
 
@@ -24,8 +25,10 @@ REPLY PWD 314 bluah you f00l!
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
+EPSV
 PASV
 TYPE I
+SIZE 124
 RETR 124
 </protocol>
 </verify>
diff --git a/tests/data/test400 b/tests/data/test400
index 1159ee8596..2c118b83dc 100644
--- a/tests/data/test400
+++ b/tests/data/test400
@@ -25,6 +25,9 @@ FTPS dir list PASV
  <command>
 ftps://%HOSTIP:%FTPSPORT/
 </command>
+<file name="log/ftpserver.cmd">
+REPLY EPSV 500 no such command
+</file>
 </test>
 
 #
@@ -37,6 +40,7 @@ filter off really nothing
 USER anonymous
 PASS curl_by_daniel@haxx.se
 PWD
+EPSV
 PASV
 TYPE A
 LIST
-- 
GitLab