Win2003 can not connect ftp after opening the firewall

  

I believe many students who use the windows
server, after opening the firewall, ftp can not be connected properly, what is the cause? ? Today is also the US Network
to talk about the basic principles of ftp transmission and the solution that can not be connected properly.

The ftp transmission data is divided into two modes: passive mode (passive mode) and port mode (active mode).

First talk about passive mode, also known as ftp passive mode. When you connect to the server on the client, the client opens two ports X and X+1 (where X is greater than 1024 for non-privileged ports), client port X sends a connection request to the server (port 21), and the server receives the request. After the request, open a random port Y (a non-privileged random port greater than 1024) and tell the client to let it connect, then the client uses the X+1 port to connect to the server's port Y, so the client and server connection Even if it is completed, after knowing the connection process, the firewall can be connected normally when the firewall is closed. However, when the Windows Firewall is opened, except for the common ports such as 80 and 21, the other ports are closed. When the client requests the server, the port opened by the server is random and is not in the firewall's exception port. Within, there will be cases where ftp cannot be connected properly.

Secondly talk about port mode, also known as ftp active mode. When the client requests a connection from the server, it uses its own random port X (a non-special port larger than 1024) to connect to the server's port 21, and then the client opens an X+1 to start listening and sends a port X+. The command of 1 is given to the server. Then, the server uses its own port (such as 21) to connect to the port X+1 sent by the client, thus completing the connection between the client and the server.

Understanding the ftp active connection and passive connection mode, when we open the firewall on the server, to ensure that ftp can be connected properly, we only need to use the ftp port mode connection on the client. Because port mode does not require the server to open other random ports. Client ftp uses more than flashfxp, we open flashfxp, modify its transfer mode, the specific steps, open flashfxp - Options - parameter settings - proxy, will "use passive mode" rdquo; .




Copyright © Windows knowledge All Rights Reserved