Layering concepts, OSI and TCP/IP stacks, packet/circuit/virtual circuit switching, data link layer (framing, error detection, MAC, Ethernet bridging), routing protocols (shortest path, flooding, distance vector, link state), IP addressing, fragmentation, IPv4, CIDR, ARP/DHCP/ICMP, NAT, transport layer (flow control, congestion control, UDP, TCP, sockets), application layer (DNS, SMTP, HTTP, FTP, email).
Protocol layering: each layer provides services to layer above.
OSI: 7 layers (physical, data link, network, transport, session, presentation, application). TCP/IP: 4 layers (network interface, internet, transport, application).
Packet switching: data divided into packets, store-and-forward.
Circuit switching (dedicated path), virtual circuit (pre-established route).
Framing, error detection, flow control, media access control.
Byte stuffing, bit stuffing, length field.
Parity, checksum, CRC (cyclic redundancy check).
Multiple access protocols: ALOHA, CSMA, CSMA/CD (Ethernet), CSMA/CA (Wi-Fi).
Bridges connect LAN segments using MAC addresses. Spanning tree protocol (STP).
Algorithms for best path: RIP (distance vector), OSPF (link state), BGP (path vector).
Dijkstra's algorithm, Bellman-Ford, used in routing.
Forward every incoming packet to all ports (except where arrived). Used for broadcasting.
DV: share entire routing table with neighbors (RIP). LS: share link state info with all routers (OSPF).
IPv4 address classes, subnetting, CIDR, fragmentation of IP packets at routers.
32-bit addresses, dotted decimal. Header format (version, IHL, TOS, total length, TTL, protocol, checksum, source/dest IP).
Classless Inter-Domain Routing: address/mask (e.g., 192.168.1.0/24).
ARP: IP to MAC address mapping. DHCP: dynamic IP assignment. ICMP: error reporting and ping.
Mapping private IPs to public IP, using port numbers.
Flow control (sliding window, TCP window), congestion control (AIMD, slow start, congestion avoidance, fast retransmit/recovery).
Connectionless, unreliable, no flow/congestion control. Header: source port, dest port, length, checksum.
Connection-oriented, reliable, in-order, flow/congestion control, full-duplex. Header: sequence number, ACK number, flags (SYN, ACK, FIN, RST), window size, checksum, urgent pointer.
Endpoint for communication: IP address + port number.
Domain Name System: translates domain names to IP addresses.
Simple Mail Transfer Protocol for email delivery.
Hypertext Transfer Protocol: request/response, methods (GET, POST, PUT, DELETE), status codes, headers.
File Transfer Protocol: uses two channels (control port 21, data port 20).
Email architecture: MUA, MTA, MDA. Protocols: SMTP, POP3, IMAP.