Networking · 16 · 3 min read
Firewalls
The bouncer at the door: it checks traffic against rules and decides what gets in and out.
Kinds of firewalls
- Packet filter — looks at IPs and ports only.
- Stateful — remembers connections and lets replies back in automatically.
- Next-gen (NGFW) — also understands apps, users and known attacks.
- Host firewall — on the computer itself (Windows Defender Firewall, macOS, ufw).
The golden rule
Default deny: block everything, then allow only what is needed. Rules are read from top to bottom and the first match wins — order matters.