
HTTP
Hyper Text Transport Protocol, a text based request-response protocol which works at the application layer. It follow certain rules for which a client/browser and a server communicates.
It was designed for transmitting message back and froth between a web client/browser and a web server. When a user issue a URL in the browser, HTTP client (Web browser) then issue an HTTP request (URL – GET/POST) to a HTTP server (Apache Server), which will return a HTTP response (HTML/Text/Audio/Video) back to the HTTP client. Depending upon the request, a response contains the status of the request.
As HTTP is both Request (Header + Body )and Response(Header + Body), this is how HTTP Request (In RED) and Response (In Blue) look in wireshark.
How HTTP Works :
Step 1) Client issue a request
Step 2) Server response to that request
Step 1: Client/Browser perform a request:
HTTP request method:
GET Method, URL, protocol version.
It has the HTTP request
HTTP request header:
Content type, length, value.
It has the request
HTTP request body:
It has the message
HTTP Request Raw data:
This is how it looks to the server when client use GET Header for Request:
The HTTP Request body is optional for an HTTP message, if it’s available, then it will carry the entire body associate with the request or response which will contain Content Type and Length header a.k.a the actual HTTP request and response data.
HTTP Request Message Body would look like this:
Step 2: Server Response to the request:
Protocol and it’s description:
POST Method
It has the HTTP response
HTTP response header:
Content type, length, value
It has the version server machine
HTTP response body:
It has the actual response
HTTP Response raw data:
This is how it looks to the client when server use POST Header for Response:
Response Body:
Some of the Request and Response Headers:
Request Headers: Accept, Cookie, Date, Host, Content Length, Content Type…
Response Headers: Allow, Connection, Content Encoding, Content Language, Content Type, Data.


One Comment
Unknown
Brilliant work!