15
27-Oct-03 Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The needs: - Different file name conventions Different representation of text and data Different directory structures

27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

Embed Size (px)

Citation preview

Page 1: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

27-Oct-03 Application Layer

File Transfer Protocol (FTP)

The standard mechanism provided by the Internet for copying a file from one host to another.

The needs: - Different file name conventions Different representation of text and

data Different directory structures

Page 2: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

27-Oct-03 Application Layer

FTP (Continued…)

Differs from other client-server applications in that it establishes two connections between the client and the server. They are: - Data connection

Used for data transfer Consists of complex rules due to the variety

of data being transferred Control connection

Used for information control (commands and responses)

Uses very simple rules of one line command or response at a time

Page 3: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

27-Oct-03 Application Layer

FTP Model

FTP client has three components User interface Client control process Client data transfer process

FTP server has two components Server control process Server data transfer process

Page 4: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

Figure 26.12 FTP

Page 5: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

27-Oct-03 Application Layer

FTP Connections

Control connection Maintained during the entire FTP

session Uses port 21 Involves interactive connection

between user and server Data connection

Maintained only during a file transfer Uses port 20

Page 6: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

27-Oct-03 Application Layer

FTP Communications

Communication over control connection Uses ASCII character set, similar to

SMTP

Communication over data connection File type Data structure Transmission mode

Page 7: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

Figure 26.13 Using the control connection

Page 8: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

Figure 26.14 Using the data connection

Page 9: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

27-Oct-03 Application Layer

File Transfer

File transfer in FTP can mean one of the following three: - Storing a file Retrieving a file Retrieving a list

Most operating systems provide user interface to access the services of FTP where the chosen activity is automatically converted by the interface to the corresponding FTP commands.

Page 10: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

Figure 26.15 File transfer

Page 11: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

Figure 26.16 Example 1

Page 12: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

List of FTP commands in DOSList of FTP commands in DOS

Page 13: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

List of FTP commands in UNIXList of FTP commands in UNIX

Commands

!, $, account, append, ascii, bell, binary, bye, case, cd, cdup, close, cr, delete, debug, dir, discount, form, get, glob, hash, help, lcd, ls, macdef, mdelete, mdir, mget, mkdir, mls, mode, mput, nmap, ntrans, open, prompt, proxy, sendport, put, pwd, quit, quote, recv, remotehelp, rename, reset, rmdir, runique, send, status, struct, sunique, tenex, trace, type, user, verbose,?

Page 14: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

27-Oct-03 Application Layer

FTP Connection Example

Page 15: 27-Oct-03Application Layer File Transfer Protocol (FTP) The standard mechanism provided by the Internet for copying a file from one host to another. The

27-Oct-03 Application Layer

GUI FTP Example