ACLs
An ACL is read top to bottom, and the first match decides
An ACL is checked line by line; the first match permits or denies, and an implicit deny drops everything that matches nothing.
An access control list is a list of rules a router checks for each packet. Packet A comes from the 10.1.20 network to the server on port four four three. Line ten matches: permitted. Checking stops there. Packet B wants SSH on port twenty-two. Line ten does not match, line twenty does: denied. Packet C wants four four three, but from 10.1.30. No line matches, so it reaches the line you never see: deny everything.
ACLs · Going deeper
Standard and extended ACLs, wildcard masks and placement
Standard ACLs match only the source and go near the destination; extended ACLs go near the source. A wildcard mask inverts the subnet mask.
Firewalls
A stateful firewall remembers conversations and separates zones
A stateful firewall lets replies back in automatically; public servers sit in a screened subnet (DMZ) between trusted and untrusted zones.
Inside users connect out to the internet. The firewall records each connection, so the replies are let back in, and nothing else is. The public web server sits in its own zone, the screened subnet. The internet may reach it on port four four three, and it may reach the database inside on one port only. Nothing from outside reaches the inside directly. If the web server is broken into, the attacker is still outside the inner zone.
VPNs
A VPN carries private traffic across the internet, encrypted
IPsec joins sites with ESP (protocol 50) and IKE (UDP 500/4500); remote users use TLS or IPsec. Tunnel mode turned 1400 bytes into 1456.
The head office and the branch each have a router. Instead of a private line, they build an encrypted tunnel over the internet, and traffic between the two networks travels inside it. A remote worker’s laptop builds its own tunnel to the office. Inside the tunnel, each original packet is encrypted and wrapped in a new one: a 1400-byte packet grows to 1456 bytes.
Access control
802.1X keeps a port shut until the user proves who they are
802.1X has a supplicant, an authenticator and a RADIUS authentication server; the answer can place the user in a VLAN.
Three roles: the device asking to join, the switch it plugs into, and a RADIUS server holding the accounts. Until the device logs in, the switch port passes nothing but login messages, which it relays to the server. The server accepts, and can tell the switch which VLAN to put the user in. Only then does the port open.
Access control · Going deeper
AAA with RADIUS and TACACS+
AAA: authentication, authorisation, accounting. RADIUS (UDP 1812) serves network access; TACACS+ (TCP 49) serves device administration.
Layer 2 security
Switch features stop attacks that start inside the LAN
DHCP snooping drops rogue offers on untrusted ports and builds a binding table; dynamic ARP inspection uses it to drop forged ARP.
Someone plugs a rogue DHCP server into a desk port. DHCP snooping trusts only the uplink towards the real server, so the rogue offers are dropped. It also records every real lease: which MAC, which address, which port. An attacker sends ARP replies claiming to be the gateway, to intercept traffic. Dynamic ARP inspection checks them against that table, finds no match, and drops them.
Layer 2 security · Going deeper
Port security
Port security limits MAC addresses per port; violation modes are protect, restrict and shutdown, which err-disables the port.
Threats
Each common attack has a matching defence
Know the attacks: DDoS, on-path, DNS poisoning, VLAN hopping, MAC flooding, rogue DHCP and APs, phishing, malware, and their defences.
Here are the attacks that come up again and again, each with the defence that answers it. Most of the defences are features you have already met: dynamic ARP inspection, DHCP snooping, port security, turning off trunk negotiation. The rest are about people and process: training, multi-factor sign-in, patching and backups.
Threats · Going deeper
Zero trust
Zero trust verifies identity and device on every request, applies least privilege and micro-segmentation, and trusts no network location.
Lesson complete
You finished “Network security”
Nicely done.