David,

I know this might be a bit vague but I seem to recall discovering the ftp
client you use at the command prompt doesn't do something it should.  eg
perhaps it doesn't support PASV or something like that.  I know we can't
connect to our ftp server from it and have to use windows explorer or
pretty much any other client.  I think the problem is you're trying to use
an inferior client that doesn't work properly.

Most of the problems I've had have been around the active ports.  Are you
using an unusual active port range? Maybe ftp.exe isn't negotiating the
active port correctly?

David

"If we can hit that bullseye, the rest of the dominoes
 will fall like a house of cards... checkmate!"
 -Zapp Brannigan, Futurama


On 17 October 2013 16:51, Greg Keogh <g...@mira.net> wrote:

> David, FileZilla works perfectly by default and lists the files and I can
> see the following in the trace (pasted below). What it's doing seems to
> make sense, but if I try similar requests from the command prompt
> (including the PASV) I still get "501 Server cannot accept argument" when I
> attempt to list or get files.
>
> So although I can now see Windows Explorer and FileZilla all listing files
> on the FTP server, I can't do the same from the command prompt. The point
> of all this simulation from the command prompt is that if I get it working
> I can then tell the C++ programmer exactly what steps I performed in the
> hope he can do the same from his code and overcome our problem.
>
> Greg K
>
> =====================
> Status: Resolving address of ftp.#######.com
> Status: Connecting to ###.50.142.77:21...
> Status: Connection established, waiting for welcome message...
> Response: 220 Microsoft FTP Service
> Command: USER ######
> Response: 331 Password required for ######.
> Command: PASS ********
> Response: 230-Welcome to the #######.com FTP service on the dedicated
> ##### server.
> Response: 230 User logged in.
> Command: SYST
> Response: 215 Windows_NT
> Command: FEAT
> Response: 211-Extended features supported:
> Response:  LANG EN*
> Response:  UTF8
> Response:  AUTH TLS;TLS-C;SSL;TLS-P;
> Response:  PBSZ
> Response:  PROT C;P;
> Response:  CCC
> Response:  HOST
> Response:  SIZE
> Response:  MDTM
> Response:  REST STREAM
> Response: 211 END
> Command: OPTS UTF8 ON
> Response: 200 OPTS UTF8 command successful - UTF8 encoding now ON.
> Status: Connected
> Status: Retrieving directory listing...
> Command: PWD
> Response: 257 "/" is current directory.
> Command: TYPE I
> Response: 200 Type set to I.
> Command: PASV
> Response: 227 Entering Passive Mode (###,50,142,77,203,156).
> Command: LIST
> Response: 150 Opening BINARY mode data connection.
> Response: 226 Transfer complete.
> Status: Calculating timezone offset of server...
> Command: MDTM 23456781.rlf
> Response: 213 20111220002502
> Status: Timezone offsets: Server: -25200 seconds. Local: 0 seconds.
> Difference: 25200 seconds.
> Status: Directory listing successful
>
>
> On 17 October 2013 15:01, David Connors <da...@connors.com> wrote:
>
>> On Thu, Oct 17, 2013 at 1:47 PM, Greg Keogh <g...@mira.net> wrote:
>>
>>> Chaps, FileZilla or Wireshark! The former I haven't used and I won't
>>> learn anything if works or nor, unless it has some tracing facility.
>>>
>>
>> You will learn exactly what the problem is.
>>
>> If it works with FileZilla using passive FTP then the problem is your
>> firewall. Windows command-line FTP is active by default.
>>
>> With active FTP the server opens the data connection to you which is
>> blocked unless you have a firewall that does stateful inspection.
>>
>> WIth passive FTP the client opens the data connection and that will work
>> by default in most NAT/firewalls even without stateful inspection.
>>
>> David.
>>
>
>

Reply via email to