Download Reference Manual
The Developer's Library for D
About Wiki Forums Source Search Contact

FTP broken (again)

Moderators: kris

Posted: 04/02/08 11:48:02

Hi,

I've updated to Tango trunk a day or two ago (don't know the revision number) and it broke my FTP stuff again. Calling ftp.ls throws "501 CLIENT: Bad syntax in MLSx response".

Thanks, bobef

Author Message

Posted: 04/02/08 22:13:33

Hey Bobef, I think the problem is that your server you queried has support for the MLST command and that the current mlst response parser apparently couldn't understand the syntax of the MLST command's response. I think a solution would be to somehow make the current FtpConncetion? have the option to only use standard. I'm working on a new FtpConnection?(FtpClient?.d) that is compatible with Input/OutputStreams so I can't fix this for you or find a fix for it(plus I've not got to the part that tells how to deal with a MLST response). Lester L. Martin II

Lester L. Martin II

Posted: 04/03/08 06:33:36

I don't know what MLST is, but it worked fine with 0.99.5 on the same server.

Posted: 04/03/08 06:55:37

bobef; do you have the opportunity to check again with 0.99.5? We should try to rule out that the server you connect against wasn't upgraded in the meanwhile.

Also compile in debug output for the command in question - such that you can see the claimed failing command.

Posted: 04/03/08 18:28:53

bobef; do you have the opportunity to check again with 0.99.5? We should try to rule out that the server you connect against wasn't upgraded in the meanwhile.

It is my local test server (filezilla,windows), so I am pretty sure it is not upgraded. I reversed to 0.99.5 and it continued working fine.

Also compile in debug output for the command in question - such that you can see the claimed failing command.

Please excuse my ignorance, but how to do that?

Posted: 05/08/08 19:35:21

Hey Bobef, The problem was that regex has something wrong when it deals with newlines. I made the new FtpClient? fall back to LIST if MLST fails. A couple of parts will fail due to regex and I have fixed most to work around regex failures. It is in the branches/lmartin in svn. It seems to work well with ZftpServer? and FileZilla?.

Lester L. Martin II

Lester L. Martin II

Posted: 05/13/08 17:56:06

lmartin92 wrote:

Hey Bobef, The problem was that regex has something wrong when it deals with newlines. I made the new FtpClient? fall back to LIST if MLST fails. A couple of parts will fail due to regex and I have fixed most to work around regex failures. It is in the branches/lmartin in svn. It seems to work well with ZftpServer? and FileZilla?.

Lester L. Martin II

Lester L. Martin II

I thought the new Tango regex was supposed to solve some kind of problems with the old one :) Anyway, thank you.

Posted: 05/19/08 13:19:24

Are you saying that my one worked...... Well, I don't know about what problems the new regex is supposed to fix, but it for some reason never handled newlines correctly on FTPConnection and continually crashed it in connections to a well and lesser known FTP server. I use ZFTPServer but tested with FileZilla?, and it had that problem until I checked for newline and removed all after newline.

Glad to hear that this thing works on more computers than mine. I can't wait till it's included in Tango.

Lester L. Martin II

Lester L. Martin II