1 / 16

HTTP

Web. HTTP. Hypertext Transfer Protocol. Web. Terminology. Message: The basic unit of HTTP communication, consisting of structured sequence of octets matching the HTTP syntax and transmitted via the connection. Request: An HTTP request message. Response: An HTTP response message.

kkenner
Download Presentation

HTTP

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Web HTTP Hypertext Transfer Protocol

  2. Web Terminology • Message: The basic unit of HTTP communication, consisting of structured sequence of octets matching the HTTP syntax and transmitted via the connection. • Request: An HTTP request message. • Response: An HTTP response message. • Resource: A netword data object or service that can be identified by a URI.

  3. Web Terminology • Entity: The information transferred as the payload of a request or response. An entity consists of metainformation in the form of entity-header fields and content in the form of an entity-body. • Representation: An entity included with a response that is subject to content negotiation. There may exist multiple representation associated with a particular response status.

  4. Web Terminology • Content Negociation: The mechanism for selecting the appropriate representation when servicing a request. • Variant: A resource may have one, or more than one, representation(s) associated with it at any given instant. Each of these representations is termed as ‘variant’. • Client:A program that establishes connections for the purpose of sending requests.

  5. Web Terminology • User agent: The client which initiates a request. These are often browsers, editors, spiders (web-traversing robots), or other end user tools • Cache: A program’s local store of response messages and the subsystem that controls its message storage, retrieval, and deletion. A cache stores cachable responses in order to reduce the response time and network bandwith consumption on future, equivalent requests. Any client or server may include a cache, though a cache cannot by used by a server that is acting as a tunnel.

  6. Web Terminology • Cachable: A response is cachable if a cache is allowed to store a copy of the response message for use in answering subsequent requests (see rules in ref.). Even if a resource is cachable, there may be additional constraints on whether a cache can use the cached copy for a particular request. • Gateway: A server which acts as an intermediary for some other server. Unlike a proxy, a gateway receives requests as if it were the origin server for the requested resource; the requesting client may not be aware that it is communicating with a gateway.

  7. Web Terminology • Tunnel: An intermediary program which is acting as a blind relay between two connections. Once active, a tunnel is not considered a party to the HTTP communication, though the tunnel may have been initiated by an HTTP request. The tunnel ceases to exists when both ends of the relay connections are closed.

  8. Web Terminology : URL

  9. Web HTTP overview • Webs application layer protocol • Client/Server model • Client - browser that requests, receives, displays web objects • Server - web server sends object in response to requests • Uses TCP sockets • Browser initiates TCP connection to server on port 80 • Stateless – server maintains no information about past browser requests

  10. HTTP Example • User enters URL www.someschool.edu/somedept/home.index • Referenced object contains HTML text and references 10 JPEG images • Browser sends an HTML “Get” request to the server www.someschool.edu • Server will retrieve and send the HTML file • Browser will read the file and sequentially make 10 separate requests for the embedded JPEG images

  11. Request line Web Optional header lines i.e. HTML doc HTTP message format • Two types of HTTP message format : request, response

  12. Web HTTP Request Message • The initial line is different for the request than for the response. A request line has three parts, separated by spaces: a method name, the local path of the requested resource, and the version of HTTP being used. • A typical request line is: • GET /path/to/file/index.html HTTP/1.0 • Notes: • GET is the most common HTTP method; it says "give me this resource". Other methods include POST and HEAD.

  13. Web HTTP Request Message

  14. Response line Optional header lines Web i.e. HTML doc HTTP Response Message

  15. Web HTTP Response Message • The initial response line, called the status line, also has three parts separated by spaces: the HTTP version, a response status code that gives the result of the request, and an English reason phrase describing the status code. • Typical status lines are: • HTTP/1.0 200 OK or HTTP/1.0 404 Not Found • Notes: • The status code is a three-digit integer, and the first digit identifies the general category of response: • 1xx indicates an informational message only • 2xx indicates success of some kind (example: 200 OK) • 3xx redirects the client to another URL • 4xx indicates an error on the client's part (example: 404 Not Found) • 5xx indicates an error on the server's part

  16. Web HTTP Response Message

More Related