The The Internet is an interconnected collection of netw orks.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-1 ! Communications Network: A facility that provides a data transfer service among stations attached to the network. ! Internet: A collection of interconnected communications netw orks. ! Subnetwork: A constituent network of an internet. ! Intermediate System (IS) or Interw orking Unit (IWU): A device used to interconnect two subnetworks and permit communications between end systems attached to different subnetworks. ! Bridge: An IWU used to interconnect tw o or more LANs. A bridge operates at layer 2 of the OSI model. ! : A device used to interconnect two or more networks at layer 3 of the OSI model.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-2 Requirements for Internetworking ! Provide a link betw een netw orks. ! Provide for and delivery of data between processes on different netw orks. ! Provide an accounting service that keeps track of the use and status of the various netw orks and IWUs. ! Accommodate differences among netw orks: - network service - addressing - routing - quality of service - maximum packet size - flow and congestion control - error reporting

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-3 Addressing ! Network Service Access Point (NSAP): - Uniquely identifies a DTE w ithin the internet (global internet address). - A DTE may have more than one NSAP. - Usually has the form (netw ork, ). ! Subnetwork Attachment Point Address (Network Point of Attachment): - Each subnetw ork must maintain a unique address for each DTE attached to that subnetwork. - One must assume that the subnetwork attachment point address has significance only within a particular subnet. - The interw orking facility must translate betw een the global address and the locally significant address.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-4 Bridge Operation ! A bridge is considered a MAC-layer relay betw een LANS (IEEE 802.1). Functions of a Bridge between LAN A and LAN B: ! Read all frames transmitted on LAN A, and copy those addressed to stations on LAN B. ! Using the MAC protocol for LAN B, retransmit those frames onto LAN B. ! Do the same for LAN B - to - LAN A traffic.

Bridge Operation

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-5 LAN Interconnection

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-6 Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-7 Connectionless Internetworking - The IP Approach The (IP) is a DoD standard. It provides connectionless service betw een stations. A connectionless internet facility is flexible in that it requires very little of its constituent netw orks.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-8 Internet Protocol Operation

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-9 Design Issues Routing: Routing is generally accomplished by maintaining a at each station and each router that gives, for each possible destination network, the next router to which the IP datagram should be sent. The routing table may be static or dynamic. A static table could contain alternate routes for use when a router is unavailable. Source routing may also be used. Datagram Lifetime: Each datagram is marked with a lifetime (e.g., hop count). Once the lifetime expires, the datagram is discarded. Segmentation and Reassembly: Where should the reassembly take place? Error Control: When a router discards a datagram, it should attempt to return some information to the source.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-10 DoD Internetwork Protocol Standard IP Services: ! Send Primitive: Used to request transmission of a data unit Includes the follow ing fields: a) Source Address - internetw ork address b) Destination Address - internetw ork address c) Protocol - identifies the recipient protocol entity (IP user). d) Type of Service Indicators: i) Precedence - 8 levels ii) Reliability - 2 levels iii) Delay - 2 levels iv) Throughput - 2 levels e) Identifier - used, along with source and destination addresses and user protocol, to uniquely identify the data unit. f) Don't Fragment Flag g) Time to Live - measured in netw ork hops. h) Data Length - length of user data field. i) Option Data - options requested by the IP user i) Security - add security label to data unit (e.g., SECRET, CONFIDENTIAL, etc.)

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-11 ii) Source Routing - a sequenced list of routers. iii) Record Routing - track the route iv) Stream Identification - Reserve resources for stream service (e.g., voice). IP must endeavor to maintain a constant delay per datagram. v) Timestamp - routers add a timestamp. j) Data - user data to be transmitted ! Deliver Primitive: Used by IP to notify a user of the arrival of a data unit. Contains the follow ing fields: a) Source Address b) Destination Address c) Protocol d) Type of Service Indicators e) Data Length f) Option Data g) Data

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-12 IP Protocol IP Datagram Format: ! Version (4 bits) ! Internet Header Length (IHL) (4 bits) Length of header in 32-bit w ords (min value is 5) ! Type of Service (8 bits) Precedence, Delay, Throughput ! Total Length (16 bits) Total data unit length, including header, in octets ! Identifier (16 bits) Used to uniquely identify the datagram ! Flags (3 bits) - More Flag - Don' t Fragment Flag - Not Used Currently ! Fragment Offset (13 bits) In 64-bit units (or 8-octet units) ! Time to Live (8 bits) In seconds ! Protocol (8 bits) Next level protocol w hich is to receive the data field at the destination. ! Header Checksum (16 bits) One's complement of all 16-bit words in the header. ! Source Address (32 bits)

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-13 ! Destination Address (32 bits) Coded to specify netw ork and station. (Options: 7 and 24, 14 and 16, 21 and 8, or 28 bit multicast.) ! Options (variable) Encodes the options requested by the user ! Padding (variable) Used to ensure that header ends on a 32-bit boundary. ! Data (variable number of octets) Max length of data field + header is 65,535 octets.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-14 IP Datagram Format

0 15 16 31

Ver IHL Type of Total Length Service

Identifier D M Fragment Offset

Time to Protocol Header Checksum Live

Source Address

Destination Address

Options and Padding

Data

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-15 IP Address Structure

! IP addresses are communicated as four bytes using dotted decimal notation. e.g., 00001010 00000000 00000000 00000000 = 10.0.0.0 (Class A netid= 10 (ARPANET)) 10000000 00000011 00000010 00000011 = 128.3.2.3 (Class B netid= 128.3 hostid= 2.3) 11000000 00000000 00000001 11111111 = 192.0.1.255 (Class C netid= 192.0.1 all hosts broadcast)

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-16 IP Subnet Addressing ! A Campus Netw ork w ith Several Subnets:

! Subnet Mask:

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-17 Example of Subnet Addressing

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-18 IP Fragmentation and Reassembly Concerned w ith issues relating to the transfer of user messages across subnets w hich support smaller packet sizes than the user data. ! Intranet Fragmentation: Fragmentation and reassembly are performed on a per network basis. Reassembly takes place at each IS. ! Internet Fragmentation: Reassemble occurs only at the destination ES.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-19 Internet Control Message Protocol (ICMP) ! Provides feedback about problems in the internet communications environment. ! ICMP is a user of IP. ICMP Message Formats:

0 15 16 31 Type = 1..11 Code Checksum Parameters

Information

! Type (8 bits) 1. Destination Unreachable 2. Time Exceeded 3. Parameter Error 4. Source Quench - (used to reduce datagram rate) 5. Redirect - (use alternate gateway) 6. Echo - (used to check reachability) 7. Echo Reply 8. Timestamp - (used to determine transit delay) 9. Timestamp Reply 10. Address Mask Request - (used to determine address) 11. Address Mask Reply mask of a subnet)

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-20 IPv6 (IPng) The driving motivation for the adoption of a new version of IP was the limitation imposed by the 32-bit address field of IP. The Internet Engineering Task Force (IETF) is the parent body of IPv6. IPv6 includes the following enhancements over IPv4: ! Expanded Address Space: IPv6 uses 128-bit addresses. ! Improved Option Mechanism: Options are placed in optional headers that need not be examined by routers on the packet' s path. ! Address Autoconfiguration: Provides for dynamic assignment of IPv6 addresses. ! Increased Addressing Flexibility: IPv6 includes the concept of an address in which a packet is delivered to just one of a set of nodes. In addition, the scalability of multicasting is improved. ! Support of Resource Allocation: IPv6 enables the labeling of packets belonging to a particular traffic flow for which special handling is requested (e.g., real-time video). ! Security Capabilities: Support for authentication and privacy.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-21 General Form of an IPv6 Packet ! IPv6 Packet Format:

! Extension Headers: - Hop-by-Hop Options Header: Defines options that require hop-by-hop processing. - Routing Header: Provides extended routing (similar to source routing). - Fragment Header: Contains fragmentation and reassembly information. - Authentication Header: Provides packet integrity and authentication. - Encapsulating Security Payload Header: Provides privacy. - Destination Options Header: Contains optional information to be examined by the destination node.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-22 IPv6 Base Header

! VERSION: ip VERSION NUMBER - 6 ! FLOW LABEL: Used by routers to associate a packet with specific flow and priority requirements. ! PAYLOAD LENGTH: Length of the IPv6 packet following the base header. ! NEXT HEADER: Identifies the type of header immediately following the IPv6 base header. ! HOP LIMIT: Remaining number of allowable hops for this packet. Each node that forwards this packet, decrements this value by 1. The packet is discarded when HOP LIMIT reaches 0.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-23 Sample IPv6 Packets

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-24 ICMPv6 Message Formats

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-25 Internet Routing ! The Internet is viewed as a collection of separately managed and run . ! Each component internet is treated as an autonomous system with its own internal routing algorithms and management authority. ! The combined Internet. therefore, is considered as being made up of a core backbone network to which are attached a number of autonomous systems. ! Exterior Gateways (or Routers) (EGs) connect an autonomous system to the core network. ! Interior Gateways (or Routers) (IGs) are used to interconnect subnets w ithin an autonomous system.

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-26 Application of Exterior and Interior Routing Protocols

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-27 Routing Protocols - Scope and Sample Tables

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-28 Internet Routing Protocols Address Resolution Protocol (ARP) ! Each interior gateway maintains a local routing table with the IP/NPA (hostid/NPA) address pair for all hosts that are attached to each of the netw orks to which it itself is attached. (Each host informs the interior gatew ay of its existence by sending it its IP/NPA pair.) ! The IP in each host maintains a local routing table of IP/NPA (hostid/NPA) address pairs for all hosts on its netw ork w ith w hich it communicates. ARP is used to obtain an NPA address when it is not present in the table. Interior Router Protocol (IRP): Used to pass routing information between routers w ithin an autonomous system (e.g. RIP, OSPF). Exterior Router Protocol (ERP): Used to pass routing information between routers in different autonomous systems (e.g. EGP, BGP).

Copyright © December 21, 2004 by Chaim Ziegler, Ph.D. Internetw orking-29