Fonte,
Whenever a FTP client requests a directory listing, this creates a new TCP connection. This connection is commonly referred to as a data connection, although the "data" it contains is a list of files/directories. This explains why you noticed ASCII mode and the "ls" (dir) command.
By default, graphical FTP clients like FileZilla automatically request a server directory listing for you, hence explaining a data connection even when not up/downloading any "real" files yet.
Hope this answers your question.
Best regards,
Tom Heyligen.
-----Original Message-----
From: ethereal-users-bounces@xxxxxxxxxxxx [mailto:ethereal-users-bounces@xxxxxxxxxxxx]On Behalf Of fonte fonte
Sent: woensdag 8 maart 2006 11:41
To: ethereal-users@xxxxxxxxxxxx
Subject: [Ethereal-users] 3 TCP Connections Instead of 2
Hi list
Another question from me. Why do I see 3 TCP (1 control and 2 data) connections for my FTP download instead of the usual 2 connections (1 control and 1 data)?
This is what I usually get from my captures:
On control connection (port 21):
Login to server
Access file folder
Request for file download etc
The last command I get before data connection takes over is 'FTP response 150 opening binary mode data connection for ftp_sco_com.tar'. Then right after that on data connection (port 20), the download begins after handshake.
So I only have 2 TCP connections.
However, of late, there's always an extra data connection created everytime I did the download.
On control connection everything was fine, however, I noticed that the last command I got before the first data connection took over was 'FTP response 150 opening ASCII mode for /bin/ls'. Then the first data connection took o ver, managed to send 56 bytes of data then immediately sent a FIN (and ACK,FIN by client). The content of data was the file name ftp_sco_com.tar.
After this happened, control connection continued to request for the file download and I finally got the 'FTP response 150 opening binary mode data connection for ftp_sco_com.tar'. The second data connection took over and the download begun as normal (on different client port).
So I have 3 TCP connections.
I don't have a clue why the extra data connection was created, and why it was on ASCII mode etc. To me, this data connection was a little bit 'premature', it seemed to be interrupting the process.
Hope anyone can give any ideas. By the way I set the transfer type to Auto in FileZilla.
Thanks