12 days 150 Upgrade to Pro A Aravind Student III
← Back to Dashboard
CONCEPT LESSON — HTTP ANATOMY

HTTP Request Anatomy

Raw Request
GET /products?id=104 HTTP/1.1 Host: shop.hackra.local User-Agent: Mozilla/5.0 Cookie: session=abc123 Accept: text/html
Method GET
Path /products?id=104
Headers Host, User-Agent, Cookie, Accept
Raw Response
HTTP/1.1 200 OK Content-Type: text/html Set-Cookie: session=abc123 Content-Length: 4520
Status 200 OK
Headers Content-Type, Set-Cookie
Body HTML content (4520 bytes)
Key Takeaway

The query parameter id=104 is provided by the browser and can be changed by the user. Anything received from the browser must be treated as user-controlled, including hidden form values, cookies and headers. The server must validate it.

Continue to Interactive Explorer