File Transfer Protocol


 The objectives of FTP are : 

1. To promote sharing of files (computer programs and/or data).
2. To encourage indirect or implicit (via programs) use of remote computers.
3. To shield a user from variations in file storage systems among hosts.
4. To transfer data reliably and efficiently.
 

The FTP Model


                                            -------------
                                            |/---------\|
                                            ||   User  ||    --------
                                            ||Interface|<--->| User |
                                            |\----^----/|    --------
                  ----------                |     |     |
                  |/------\|  FTP Commands  |/----V----\|
                  ||Server|<---------------->|   User  ||
                  ||  PI  ||   FTP Replies  ||    PI   ||
                  |\--^---/|                |\----^----/|
                  |   |    |                |     |     |
      --------    |/--V---\|      Data      |/----V----\|    --------
      | File |<--->|Server|<---------------->|  User   |<--->| File |
      |System|    || DTP  ||   Connection   ||   DTP   ||    |System|
      --------    |\------/|                |\---------/|    --------
                  ----------                -------------

                  Server-FTP                   USER-FTP

      NOTES: 1. The data connection may be used in either direction.
             2. The data connection need not exist all of the time.

                     
Figure :  Model for FTP Use

      In the model described in Figure 1, the user-protocol interpreter  initiates the control connection. The control connection follows  the Telnet protocol.
At the initiation of the user, standard FTP commands are generated by the user-PI and transmitted to the  server process via the control connection.
(The user may  establish a direct control connection to the server-FTP, from a TAC terminal for example, and generate standard FTP commands  independently,
 bypassing the user-FTP process.) Standard replies are sent from the server-PI to the user-PI over the control connection in response to the commands.

      The FTP commands specify the parameters for the data connection  (data port, transfer mode, representation type, and structure) and   the nature of file system
 operation (store, retrieve, append, delete, etc.).  The user-DTP or its designate should "listen" on  the specified data port, and the server initiate the data connection
and data transfer in accordance with the specified parameters.  It should be noted that the data port need not be in the same  host that initiates the FTP commands
via the control
connection, but the user or the user-FTP process must ensure a "listen" on the specified data port.  It ought to also be noted that the data connection
may be used for simultaneous sending and receiving.