protocols:http
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| protocols:http [2026/06/26 14:24] – [HTTP Request Message] v1ctor | protocols:http [2026/07/01 14:08] (current) – [Intro] v1ctor | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== HTTP ====== | ====== HTTP ====== | ||
| - | ==== Intro ==== | + | ===== Intro ===== |
| HTTP can run in two modes: | HTTP can run in two modes: | ||
| Line 12: | Line 12: | ||
| Both have a start line, headers, an empty line and optional body. | Both have a start line, headers, an empty line and optional body. | ||
| - | ==== HTTP Request Message ==== | + | |
| + | **Version** - the application doesn' | ||
| + | |||
| + | The version is **negotiated** during TLS handshake. The browser advertises the application protocols it supports using TLS extension called ALPN. | ||
| + | |||
| + | There is no TLS handshake for HTTP, so the browser simply starts with **HTTP/ | ||
| + | |||
| + | **HTTP/ | ||
| + | HTTP/3 runs on top of the QUIC (Quick UDP). The main idea that we eliminate two handshaks that were needed in HTTPs (TCP + TLS). | ||
| + | |||
| + | In QUIC TLS handshake is absorbed into the initial setup handshake. HTTP/3 does not run TLS "on top" of QUIC. Instead, **TLS 1.3** is built into the QUIC protocol itself. | ||
| + | |||
| + | QUIC mitigates HOL (Head of Line) problem by treating each stream within a single connection independently. If one particular frame is lost, QUIC will handle it separately without blocking the rest of the streams. | ||
| + | |||
| + | ===== HTTP Request Message | ||
| First line in the Request Message is called a **request** line. The subsequent lines are called **headers** line. | First line in the Request Message is called a **request** line. The subsequent lines are called **headers** line. | ||
| + | |||
| + | Request line has three fields: | ||
| + | - Method | ||
| + | - URL | ||
| + | - HTTP version | ||
| + | |||
| + | ==== HTTP Response Message ==== | ||
| + | |||
| + | First line in Response Message is called a **status** line. Then we have six **header** lines and then **entity body**. | ||
| + | |||
| + | Status line has three fields: | ||
| + | - Protocol version | ||
| + | - Status code | ||
| + | - Corresponding status message | ||
| + | |||
| + | ==== Cookie ==== | ||
| + | |||
| + | HTTP is a Stateless protocol. Cookie is the primary mechanism for maintaining state. Cookies allows a web server to know: | ||
| + | * Whether you've visited before | ||
| + | * Whether you're logged in | ||
| + | * What's in your shopping cart | ||
| + | * What language you selected | ||
protocols/http.1782483873.txt.gz · Last modified: by v1ctor
