Requirements for Internet Routers (Gateways) and Hosts Relates to Lab 3. (Supplement) Covers the compliance requirements of Internet routers and hosts. 1 What does it mean to be IP compliant? • Requirements for Internet Routers and hosts have been document in Request for Comments (RFCs) of the Internet Engineering Task Force (IETF): • RFC 985: Requirements for Internet Gateways – Draft (1986) • RFC 1009: Requirements for Internet Gateways (1987) • RDC 1716: Towards Requirements for IP Routers (1994) • RFC 1812: Requirements for IP Version 4 Routers (1995) • RFC 1122 (STD 3): Requirements for Internet Hosts - Communication Layers (1989) • RFC 1123 (STD 3): Requirements for Internet Hosts - Application and 2 Language of Requirements MUST – absolute requirement of the specification. MUST IMPLEMENT – Implementation is required, but need not be enabled by default MUST NOT – absolute prohibition of the specification. SHOULD – there may exist valid reasons to, but full implications must be understood and weighed (recommended) SHOULD NOT – there may exist valid reasons to include, but full implications must be understood and weighed (not recommended) MAY / OPTIONAL – optional 3 Robustness Principle "Be liberal in what you accept, and conservative in what you send” • The principle should be applied by all protocols to increase robustness and interoperability • Other hosts and routers may use deficient implementations ”Be Adaptive to Change" • Assume that protocol will be extended in the future, and options will be added 4 HOST REQUIREMENTS: IPv4 (partial list) MUST NOT SHOULD NOT ✔ Multiple IP addresses (“multihoming”) - local host - remote host ✔ ✔ Forward datagram received from connected network Silently discard version number ≠ 4 MAY SHOULD MUST Implement IP and ICMP ✔ ✔ Able to log discarded datagrams ✔ Src address must be host's own IP address ✔ Support reassembly ✔ 5 HOST REQUIREMENTS: IPv4 (partial list) ICMP Echo Request and Reply (client and server) Discard Echo Request to broadcast address MUST NOT Generate ICMP Dest Unreachable (code 2/3) Send ICMP Redirect Update routing table for incoming ICMP Redirect SHOULD NOT Send ICMP for ICMP Error message Send ICMP for broadcast or multicast IP datagram Send ICMP error message (if not prohibited) MAY Send packet with TTL of 0 Discard received packets with TTL < 2 Transport layer can set TTL SHOULD MUST Timestamp IP option Source route IP option ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ 6 HOST REQUIREMENTS: IPv4 (partial list) Use default gateway if no match in routing table ✔ MUST NOT ✔ SHOULD NOT Operate without router or connected network MAY ✔ SHOULD MUST Use netmask in local/remote decision for outgoing packets Ping routers continuously ✔ Use broadcast address as src IP address ✔ 7 Definition of an IP router (gateway) 1. Conforms to specific Internet protocols, including IP and ICMP 2. Interfaces to two or more packet networks – Encapsulation/decapsulation, MTU, address translation 3. Receives and forwards Internet datagrams. – Recognizes error conditions, Drop when TTL=0, perform fragmentation 4. Chooses next hop 5. Supports a routing protocol 6. System Support (debugging, status report, etc.) 8 ROUTER REQUIREMENTS: IPv4 (partial list) Support IP fragmentation First fragment is smallest Send fragments in order Generate least possible number of fragments ✔ Decrement TTL by at least one Discard packet when TTL is zero Send ICMP Error due to dropped packet with TTL=0 Generate packet with TTL=0 ✔ ✔ MUST NOT ✔ SHOULD NOT Check IP header checksum MAY ✔ SHOULD MUST Drop packets because unused IP header field values Ignore unrecognized IP options ✔ ✔ ✔ ✔ ✔ ✔ 9 ROUTER REQUIREMENTS: IPv4 (partial list) Forward destination 255.255.255.255 Forward destination with host number all `1’ Discard packets with host number all `1’ MUST NOT ✔ ✔ SHOULD NOT Be able to reboot from NOC Have mechanism for retrieving status MAY ✔ SHOULD MUST Router must operate as a stand-alone device ✔ ✔ ✔ ✔ See RFC’s for more rules. 10 HOST REQUIREMENTS: IPv4 (partial list) MUST NOT SHOULD NOT ✔ Multiple IP addresses (“multihoming”) - local host - remote host ✔ ✔ Forward datagram received from connected network Silently discard version number ≠ 4 MAY SHOULD MUST Implement IP and ICMP ✔ ✔ Able to log discarded datagrams ✔ Src address must be host's own IP address ✔ Support reassembly ✔ 11 HOST REQUIREMENTS: IPv4 (partial list) ICMP Echo Request and Reply (client and server) Discard Echo Request to broadcast address MUST NOT Generate ICMP Dest Unreachable (code 2/3) Send ICMP Redirect Update routing table for incoming ICMP Redirect SHOULD NOT Send ICMP for ICMP Error message Send ICMP for broadcast or multicast IP datagram Send ICMP error message (if not prohibited) MAY Send packet with TTL of 0 Discard received packets with TTL < 2 Transport layer can set TTL SHOULD MUST Timestamp IP option Source route IP option ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ ✔ 12 HOST REQUIREMENTS: IPv4 (partial list) Use default gateway if no match in routing table ✔ MUST NOT ✔ SHOULD NOT Operate without router or connected network MAY ✔ SHOULD MUST Use netmask in local/remote decision for outgoing packets Ping routers continuously ✔ Use broadcast address as src IP address ✔ 13 Definition of an IP router (gateway) 1. Conforms to specific Internet protocols, including IP and ICMP 2. Interfaces to two or more packet networks – Encapsulation/decapsulation, MTU, address translation 3. Receives and forwards Internet datagrams. – Recognizes error conditions, Drop when TTL=0, perform fragmentation 4. Chooses next hop 5. Supports a routing protocol 6. System Support (debugging, status report, etc.) 14 ROUTER REQUIREMENTS: IPv4 (partial list) Support IP fragmentation First fragment is smallest Send fragments in order Generate least possible number of fragments ✔ Decrement TTL by at least one Discard packet when TTL is zero Send ICMP Error due to dropped packet with TTL=0 Generate packet with TTL=0 ✔ ✔ MUST NOT ✔ SHOULD NOT Check IP header checksum MAY ✔ SHOULD MUST Drop packets because unused IP header field values Ignore unrecognized IP options ✔ ✔ ✔ ✔ ✔ ✔ 15 ROUTER REQUIREMENTS: IPv4 (partial list) Forward destination 255.255.255.255 Forward destination with host number all `1’ Discard packets with host number all `1’ MUST NOT ✔ ✔ SHOULD NOT Be able to reboot from NOC Have mechanism for retrieving status MAY ✔ SHOULD MUST Router must operate as a stand-alone device ✔ ✔ ✔ ✔ See RFC’s for more rules. 16