Advanced Computer Networks: Lecture 18. This lecture will cover the following: Internet Protocol (IP); IP addresses; concatenation of networks; datagram format; source-based routing (typically disabled); identifies packet fragments;...
CS716 Advanced Computer Networks By Dr. Amir Qayyum Lecture No. 18 Internet Protocol (IP) • Network protocol for the Internet • Operates on all hosts and routers (routers connect distinct networks into the Internet) FTP HTTP NV TFTP UDP TCP IP FDDI Ethernet … ATM Internetwork • Concatenation of networks H6 H7 H1 R1 Network Network 11 Ethernet Ethernet Network 2 Point to point H3 H2 R3 Network Network 33 FDDI FDDI R2 Network Network 44 Ethernet Ethernet H5 H8 H4 • Protocol stack H1 H8 TCP R1 IP IP ETH R2 ETH R3 IP PPP PPP IP FDDI FDDI TCP IP ETH ETH IP Addresses bits (126 nets) Class A: 24 bits (16 million hosts) Network Host 14 bits (16k nets) Class B: 16 bits (64K hosts) Network 21 bits (2 million nets) Class C: 1 – 18.10.5.22 – 130.126.143.254 – 192.12.70.111 Network Host bits (256) Host host in class A network (MIT) host in class B network (UIUC) host in class C network • More recent classes – Multicast (class D): starts with 1110 – Future expansions (class E): starts with 1111 Datagram Format Version HLen 16 TOS 31 Length Ident TTL 19 Flags Protocol Offset Checksum SourceAddr DestinationAddr Options (variable) Pad (variable) Data • • • • • 4bit version (4 for IPv4, 6 for IPv6) 4bit header length (in words, minimum of 5) 8bit type of service (TOS); more or less unused 16bit datagram length (in bytes) 8bit protocol (e.g., TCP=6 or UDP=17) Datagram Format Version HLen 16 TOS 31 Length Ident TTL 19 Flags Protocol Offset Checksum SourceAddr DestinationAddr Options (variable) Pad (variable) Data • Fragmentation support – 16bit packet ID (identifies packet fragments) – 3bit flags; one bit marks last fragment – 13bit fragment offset into packet (in 8byte words) • 8bit “timetolive” (TTL); a hop count until forced destruction of packet Datagram Format • • • • 16bit IP checksum on header 32bit source IP address 32bit destination IP address Options and padding (variable length) – Sourcebased routing (typically disabled) 16 – Record route TOS Version HLen – Several others Ident Flags TTL Protocol 19 31 Length Offset Checksum SourceAddr DestinationAddr Options (variable) Pad (variable) Data .. .Lecture? ?No.? ?18 Internet Protocol (IP) • Network protocol for the Internet • Operates on all hosts and routers (routers connect ... Host 14 bits (16k nets) Class B: 16 bits (64K hosts) Network 21 bits (2 million nets) Class C: 1 – 18. 10.5.22 – 130.126.143.254 – 192.12.70.111 Network Host bits (256) Host host in class A network (MIT)