2.5 HTTP
2.5.1 Introduction to HTTP
The Hypertext Transfer Protocol (HTTP) defines how client and server applications
communicate in order to transfer hypertext documents and other resources located on the
Internet although it is not specifically limited to the TCP/IP protocol stack. The protocol is
independent of the type of resources transferred so data may be text, sound, images, query
results from a database or even an application to be executed on the client machine.
The Hypertext Transfer Protocol (HTTP) is an application level protocol for distributed,
collaborative, hypermedia information systems. It is a generic, stateless, protocol which can
be used for many tasks beyond its use for hypertext, such as name servers and distributed
object management systems, through extension of its request methods, error codes and
headers. A feature of HTTP is the typing and negotiation of data representation, allowing
systems to be built independently of the data being transferred [15].
The format of a typical HTTP request response is as follows
1. A client opens a connection with a server.
2. The client sends a request to the server. This request consists of a request method, URI,
and protocol version, followed by a MIME like message containing request modifiers,
client information, and possible entity body content over a connection with a server.
3. The server returns to the client a status line, header information, and possibly some entity
metainformation and an entity body.
4. The server closes the connection.
HTTP is a stateless protocol in that it does not maintain any connection information between
transactions although HTTP/1.1 does support persistent connections so a connection does
not have to open each time to the fetch each URL and in doing so reduces the load on the
server. This means that if a hypertext page has embedded references to other resources, the
%