Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: Simple GET, uses MLST only in scripting mode

WinSCP needs to know file attributes. In GUI, it knows that from MLSD used for directory listing. In the script, WinSCP uses MLST because it needs attributes of a single file only. What problems does MLST cause in particular?

Note that since WinSCP 5.6 beta, you can prevent WinSCP from using MLST by open -rawsettings FtpUseMlsd=1....
See
https://winscp.net/tracker/1181
https://winscp.net/eng/docs/rawsettings
sandos

Simple GET, uses MLST only in scripting mode

When retrieving a file in the GUI, either downloading or viewing it, it looks like this:

220 MM-FTP Server Connected.
USER Administrator
331 Password required for Administrator.
PASS xxx
230 Login successful.
SYST
215 Windows_NT
FEAT
211-FEAT
SIZE
MDTM
MLSD
MLST
REST STREAM
HASH MD5*;SHA-1;SHA-224;SHA-256;SHA-384;SHA-512
XMD5
XSHA1
XSHA256
XSHA512
AUTH TLS;TLS-C;TLS-P;SSL
PBSZ
PROT C;P
211 END
PWD
257 "/" is current directory.
CWD /
200 Changed directory to /
PWD
257 "/" is current directory.
TYPE A
200 Type is ASCII.
PASV
227 Entering Passive Mode (138,227,102,235,4,48)
MLSD
150 File status ok; About to open data connection.
226 Closing data connection. Transfer ok.
TYPE A
200 Type is ASCII.
PASV
227 Entering Passive Mode (138,227,102,235,4,48)
RETR autoexec.txt
150 File status ok; About to open data connection.
250 File transfer completed for (autoexec.txt)
221 FTP Server Abort connection on timeout


And when doing something similar via command-line scripts, it looks like:


220 MM-FTP Server Connected.
USER Administrator
331 Password required for Administrator.
PASS xxx
230 Login successful.
SYST
215 Windows_NT
FEAT
211-FEAT
SIZE
MDTM
MLSD
MLST
REST STREAM
HASH MD5*;SHA-1;SHA-224;SHA-256;SHA-384;SHA-512
XMD5
XSHA1
XSHA256
XSHA512
AUTH TLS;TLS-C;TLS-P;SSL
PBSZ
PROT C;P
211 END
PWD
257 "/" is current directory.
CWD /
200 Changed directory to /
PWD
257 "/" is current directory.
TYPE A
200 Type is ASCII.
PASV
227 Entering Passive Mode (138,227,102,235,4,47)
MLSD
150 File status ok; About to open data connection.
226 Closing data connection. Transfer ok.
MLST /autoexec.txt
125 Data connection open; Transfer starting.
Type=cdir; /
Type=file;Size=1382;Modify=20141017074726;Perm=rwfd; autoexec.txt


It seems our particular FTP-server does not handle MLST very well, it is a built-in system, and I have no way of changing this. Is there any particular reason MLST needs to be used in the CLI case?