UDP services

poornima lagadapati

Active member
UDP is a no-frills, lightweight transport protocol, providing minimal services. UDP

is connectionless, so there is no handshaking before the two processes start to

communicate. UDP provides an unreliable data transfer service—that is, when a process

sends a message into a UDP socket, UDP provides no guarantee that the message

will ever reach the receiving process. Furthermore, messages that do arrive at the

receiving process may arrive out of order.

UDP does not include a congestion-control mechanism, so the sending side of

UDP can pump data into the layer below (the network layer) at any rate it pleases.

(Note, however, that the actual end-to-end throughput may be less than this rate due

to the limited transmission capacity of intervening links or due to congestion).
 
Web Caching

A Web cache—also called a proxy server—is a network entity that satisfies HTTP
requests on the behalf of an origin Web server. The Web cache has its own disk storage
and keeps copies of recently requested objects in this storage.
 
File Transfer: FTP

In a typical FTP session, the user is sitting in front of one host (the local host)

and wants to transfer files to or from a remote host. In order for the user to

access the remote account, the user must provide a user identification and a pass￾word. After providing this authorization information, the user can transfer files

from the local file system to the remote file system and vice versa. As shown in

Figure 2.14, the user interacts with FTP through an FTP user agent. The user first

provides the hostname of the remote host, causing the FTP client process in the

local host to establish a TCP connection with the FTP server process in the

remote host. The user then provides the user identification and password, which

are sent over the TCP connection as part of FTP commands. Once the server has

authorized the user, the user copies one or more files stored in the local file sys￾tem into the remote file system (or vice versa)
 
FTP Commands and Replies

We end this section with a brief discussion of some of the more common FTP com￾mands and replies. The commands, from client to server, and replies, from server to

client, are sent across the control connection in 7-bit ASCII format. Thus, like HTTP

commands, FTP commands are readable by people. In order to delineate successive

commands, a carriage return and line feed end each command. Each command con￾sists of four uppercase ASCII characters, some with optional arguments. Some of

the more common commands are given below:



USER username: Used to send the user identification to the server.



PASS password: Used to send the user password to the server.



LIST: Used to ask the server to send back a list of all the files in the current

remote directory. The list of files is sent over a (new and non-persistent) data

connection rather than the control TCP connection.



RETR filename: Used to retrieve (that is, get) a file from the current direc￾tory of the remote host. This command causes the remote host to initiate a data

connection and to send the requested file over the data connection.



STOR filename: Used to store (that is, put) a file into the current directory

of the remote host.

There is typically a one-to-one correspondence between the command that the

user issues and the FTP command sent across the control connection. Each com￾mand is followed by a reply, sent from server to client. The replies are three-digit

numbers, with an optional message following the number. This is similar in struc￾ture to the status code and phrase in the status line of the HTTP response message.

Some typical replies, along with their possible messages, are as follows:



331 Username OK, password required



125 Data connection already open; transfer starting



425 Can’t open data connection



452 Error writing file

Readers who are interested in learning about the other FTP commands and replies

are encouraged to read RFC 959
 
Back
Top