Seven layers, each with one job
Bits on a wire, frames to a neighbour by MAC, packets across networks by IP, segments to a process by port, messages by URL.
Does the internet run seven layers?
Bad: Seven, one protocol each
OSI is a reference model, not the internet’s blueprint.
Good: Four, and TLS straddles
Link, internet, transport, application. TLS spans layers 5 and 6, riding on TCP.
One 200-byte request, wrapped four times
TLS, TCP, IP and Ethernet each wrap it in their own header, never reading inside. 280 bytes cross the wire; 80 are headers.
Each box reads only as deep as its job
MAC addresses change at every router. IP survives unless NAT rewrites it. TLS survives only to the first box holding the key.
Which layer stops a login botnet?
Bad: Packet filters
Every request completes TLS from a real address, like a user.
Good: A WAF at L7
It reads each decrypted request’s path and rate. You pay to end TLS.
“The API is down”: walk up the stack
- L3:
pingandtraceroutereach the host - L4:
ncconnects to port 443 - TLS:
opensslfinishes the handshake - L7:
curl -vshows what the server says
The office VPN is up. ssh works, the login API works. Every file upload hangs.
The cause
The tunnel cut the MTU to 1,446. The ICMP “too big” reply was blocked, so full-size packets silently vanish.
Remember
OSI’s seven layers are shared vocabulary; the internet runs four. Every box reads up to some layer: a router reads IPs, an L4 balancer the 5-tuple, an L7 proxy or WAF the decrypted request.