Chapter 1
Chapter 1
Programming
Chapter 1
Introduction
The Internet – a network of networks
An infrastructure (connectivity among a large number of machines
world wide)
Several applications:
E-mal
www
File transfer (FTP)
Remote login
E-commerce
Instant messaging (chat)
Mailing lists
…
Next: HTTP
Chapter 1 --continued
HyperText Transfer Protocol (HTTP)
<html><head><title>page titiel</title></head>
<body>some content</body></html>
Examples:
Connection:close – client wants to close the connection when
the first response is complete
Cache-control – client can specify additional properties if the
requested resource is cached (e.x. age)
Date
Transfer-Encoding
…
Examples:
Content-Encoding – indicates type of content encodings applied (e.x.
zipped)
Content-Language – language of the intended audience
Content-Length – size of the entity body (message body)
Expires
…
Examples:
Accept - acceptable media types for response
Accept-Charset – acceptable character set
User-Agent – client browser
…
Examples:
Age – estimate of time since response was generated
Location – used to redirect to a different location (URI)
Proxy-Authenticate – proxy authentication challenge
Server – information about the web server software
…
Request method
GET (or retrieve) information from the server
POST (information) back to the server
HEAD – like GET but only returns meta-information
PUT (information) at the server
DELETE (information) from the server
HTTP Version
Used by the sender to notify the receiver of its abilities
Included in the first line of the message
Format: HTTP/<major>.<minor>
E.x. HTTP/1.1
Request URI
The URI of the resource requested
Status code
Has 5 categories