Networking · Part 9 ·
Finding where a request breaks
A request passes the name, the route, the port, the padlock and the answer. Each tool checks one of these steps. Go in order and stop at the first failure, and curl's error code and timings show where to look.
Networking · Part 8 ·
One front door for many programs
A reverse proxy is one address in front of many programs. It ends the client's connection and opens its own. It takes turns between the programs, but a health check that only proves the port is open sends requests into a broken one.
Networking · Part 7 ·
Where a container's network ends
A container has its own network on a private street inside the host. Docker joins that street to the outside with two rewrite rules, one for traffic that leaves and one for each published port. The second rule is applied before the host's firewall rules for incoming traffic.
Networking · Part 6 ·
Why your address is borrowed
A machine does not own its address. A DHCP server lends it, usually with a gateway and a resolver, and NAT rewrites it on the way out. A server on the internet sees the address of the translator, not yours.
Networking · Part 5 ·
What the padlock proves
HTTPS wraps the plain text of part 4, so nobody on the path can read it or change it unnoticed. The padlock proves that the name you typed matches a certificate signed by someone your machine trusts. It does not prove that the site is honest.
Networking · Part 4 ·
HTTP is just text on a connection
A web request is a few lines of plain text sent over an open connection, and the answer is a few more lines. Once you can read them, the output of `curl -v` is easy to follow. The versions of HTTP change how many requests share one connection.
Networking · Part 3 ·
What TCP promises and what it does not
TCP delivers your data in order, or it reports an error. How soon it reports depends on timers you did not set. The two errors, refused and timed out, show two different ways a connection fails.
Networking · Part 2 ·
How a name becomes an address
A packet needs an address, but people type names. DNS is a chain of questions, and every answer is kept in a cache until its time limit ends, so a changed record does not change everywhere at once.
Networking · Part 1 ·
A packet only knows the next step
A machine has no map of the internet. For every packet it asks who should get it next. The most specific route answers, and a wrong route changes only the addresses in its range.