Search Knowledge Base by Keyword

What is the Difference Between Active and Passive FTP?

FTP stands for File Transfer Protocol. FTP is an application layer protocol which transfers files over a network.

An FTP server can operate in two different modes by default – Active or Passive.

Active mode is the original FTP mode and often the default FTP mode. Here’s how a typical Active FTP transaction would take place:

  1. A user connects from their FTP client to FTP port 21 on the server. The FTP client sends the PORT command, to specify which client-side port the server should connect to. This port is used for the data channel, differing from the port used for the command channel.
  2. The FTP server connects from port 20 to the designated data channel port on the FTP client. The connection is then established, and then the file transfers are made through these ports.

Passive mode is similar to Active mode, but with a few key differences. Here’s how a typical Passive FTP transaction would take place:

  1. A user connects from a random port on their FTP client to FTP port 21 on the server, and then issues the PASV command. The FTP server then responds to indicate which port it has opened for data transfer.
  2. The user then connects from a different random port to the port specified in the server’s response. The connections is then established and the data transfer can take place between these two ports.
Was this article helpful?
0 out Of 5 Stars
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
5
How can we improve this article?
Please submit the reason for your vote so that we can improve the article.