HTTP Headers
As discussed previously, HTTP transactions consist of an HTTP method and a number of different HTTP headers. There are four basic types of HTTP headers:
General
These headers, which are used by both clients and servers, contain general information such as the date, caching, and connection status. General headers include the following: Cache-control, Connection, Date, Pragma, Trailer, Transfer-Encoding, Upgrade, Via, Warning.
Request
When a client requests content, a request header contains the client's configuration and supported data formats. Request headers include the following: Accept, Accept-Charset, Accept-Encoding, Accept-Language, Authorization, Cookie, Expect, From, Host, If-Modified-Since, If-Match, If-None-Match, If-Range, If-Unmodified, Max-Forwards, Proxy-Authorization, Range, Referer, TE (transfer encoding), User-Agent.
Response
When a server sends content to a client, response headers describe the server configuration and information about the URL that was requested. Response headers include the following: Accept-Ranges, Age, ETag, Location, Proxy-Authenticate, Retry-After, Server, Set-Cookie, Vary, WWW-Authenticate.
Entity
These headers contain information about the format of the content being sent back and forth. They can be used both by servers (when sending information) and clients (when submitting data, generally by a POST operation). Entity headers include the following: Allow, Content-Encoding, Content-Language, Content-Length, Content-Location, Content-Range, Content-Type, Expires, Last-Modified.
|