Review of last class III. Layer 3 Technology [continued] A. IP Addressing 1. Original class hierarchy 2. Special addresses B. Subnetting C. Subnet masks D. Hands-on Administrative 1. Project lists online 2. Mid-term review - end of class 3. Study guide online 4. Weblinks/readings III. Layer 3 Technology [continued] D. Supernetting Contrary to subnet addressing, which splits a larger network address space into multiple subnets, supernetting combines multiple smaller network addresses into a larger "supernet". Subnetting class A and class B networks was not enough. Supernetting arose out of the need to avoid assigning class B address space to organizations that needed something less, but more than a class C could provide. That and the fact that the Internet would soon run out of addresses! So for example, an organization could obtain multiple contiguous class C addresses and use them as appropriate instead of obtaining a class B address space, where much of it may go unused. ex: DePaul and many universities E. Classless Inter-Domain Routing With supernetting, address space could be conserved, but the information routers needed to keep was rising greatly. That is, each multiple class C address being assigned needed to exist in the router tables. There are potentially over 4 million class C networks! CIDR collapses contiguous class C addresses into a single routing entry. Example: Routing Table Entry Equates to the Following Networks ------------------- --------------------------------- [128.1.1.0,3] 128.1.1.0 128.1.2.0 128.1.3.0 3. IP Routing In order for IP datagrams to traverse across IP networks, routers are used to help move them from one network to another from source to destination. As a packet moves from router to router, an independent decision is made at each router, a "forwarding" decision which the router makes based on information in a routing table. A. Static Routes Whereas most routers "learn" how to make routing decisions, through the exchange of routing protocol control messages between each other a simple method of creating a routing table entry is to manually configure a permanant or "static" route. B. Default Route In the case where many common destination routes exist in a routing table, they can be replaced with a "default" route entry, thus saving routing table size and route lookup time. C. Routing Information Protocol A simple, interior routing protocol of the distance vector routing algorithm family. 1. RIPv1 Standardized in RFC 1058 with provisions for split horizon and triggered updates. Carried over a connectionless transport protocol, called which UDP which is in turn carried over IP. We will cover UDP later in the course. a. Frame format Command (1) Version (1) reserved (2) --+ Address family identifier (2) | reserved (2) | May be IP address (4) | repeated reserved (8) | Metric (4) --+ b. No provision for passing a mask c. Hop limit of 16 d. 30 second RIP packet broadcast interval - slow convergence 2. RIPv2 RFC 2453 adds support for subnet masks, authentication, a route tag, multicast distribution and the ability to announce routes on behalf of another router. Frame format Command (1) Version (1) reserved (2) --+ Address family identifier (2) | Route Tag/Authentication Type (2) | Authentication (16 if necessary) | May be IP address (4) | repeated Subnet mask (4) | Next Hop (4) | Metric (4) --+ D. Open Shortest Path First A link state protocol based on the distributed map concept, where all nodes have a copy of the network map with which to make independent routing decisions from. Stanardized by the IETF in RFC 2328. As RIP is limited and simple, OSPF is powerful and at least somewhat complex. With the potential size of the link state database in a large network, the duration of route computation time and the volume of messages which must be exchanged in large networks, OSPF splits the network into smaller, more manageable "areas". Each area behaves somewhat like an independent network, where the "flooding" protocol stops at the borders of the area. To bring the areas together, some routers routers belong to multiple areas. There must be at least one "area-border" for each area. These area-border routers then maintain multiple link state databases. E. Border Gateway Protocol Standardized in RFC 1771, this exterior gateway protocol (also known as a interdomain routing protocol) is the standard for routing between autonomous systems in the Internet. BGP is similar to a distance vector routing protocol, except instead of using distances (hops), you work with "paths". In this way, you receive and report the preferred paths to a destination. The primary mechanism that determines routes is by the use of "route preferences". So for example, you could configure a router whose routes are affected by: o Don't use any path that goes through autonomous system 73 o Do not report the following XYZ destinations to ABC neighbors o Edit the path information when passing it to a neighbor These configuration options allow a sort of "policy" based routing. 4. Internet Control Message Protocol (ICMP) A required piece of the TCP/IP stack, ICMP is used to report errors and gather information about a internet or internet host. Defined in RFC792. Examples: Echo Request/Reply Using ICMP to trace a route - TTL - Routers send back a TTL exceeded up until the point of reaching the host - Note: routes must be stable to be useful! - Typically send a UDP packet to a invalid port, will get back a destination unreachable ICMP packet when you've reached the host 5. Intro to IPv6 Defined by RFC2460, IP next generation (IPng) purports to supplant the current IPv4 base by offering larger addresses, integrated security mechanisms and provisions for others services such as class of service bits. A. IPv6 Addresses 16 bytes long which consists of 16-bit hex value pieces, separated by colons. i.e. 6ADF:F5A1:0:0:0:921B:681C:9100 Addresses can be compressed when sequential zeroes are present in any 16-bit piece by the use of a double colon. i.e. ::681C:9100 There are provisions to maintain the original IPv4 address space in IPv6 addresses. B. Fragmentation Issue C. Overhead D. Will it be used? For a historical look, IPng: Internet Protocol Next Generation, Bradner and Mankin ISBN: 0-201-63395-7 6. Mobile IP The requirement for Mobile IP comes from the limitations of traditional IP address and routing. Each host in a an IP network maintains a unique IP address which not only identifies a host, but also the route to that host. A mobile IP computer then, would either need to obtain a new IP address or supply new routing information for the network it is now on. Not only is this difficult to scale, but it may also break higher layer apps that require a static IP address with which to bind. A. Home Agent The home agent is essentially a forwarding agent on behalf of the mobile IP host. Typically a router, firewall or other gateway type of device performs the forwarding function when necessary. B. Foreign Agent A foreign agent is assigned to a mobile IP host whenever the mobile IP host is away from it's "home base". The foreign agent acts as a "care-of" address on the behalf of the mobile IP host. - Example mobile IP network scenarios - Supplement on course page planned IV. Layer 4 Technology The Transport layer performs three primary functions on an end-to-end basis; flow control, error control and application multiplexing. Not all transport layer protocols need to perform all these functions. For example, UDP only provides for application multiplexing. If these functions are not needed, they can go unused. i.e. voice over packet data cannot use very much error control. NOTE: I'm skipping congestion control in the lecture and leaving it to the book (read 5.3!) in order to save some time for other things. Normally we would cover it in this section. A. Error control Errors at the packet level, as opposed to the bit level (layer 2), error control is primarily handled through detection and retransmission. The receiver that receives an errored packet will reply with a negative acknowledgement (NACK or NAK) and if the packet is OK, it will response with a positive acknowledge (ACK). 1. Sequence Numbers A limited size number which indicates in each packet determines the unique position in a stream of packets from a source station. Sequence numbers help determine lost and duplicate packets as well as out-of-order packets. Note: sequence numbers should be large enough so that they do not wrap-around too quickly. 2. Three way handshake To setup sequence numbers and a reliable transport connection, sender and receiver exchange 3 messages, which are sufficient to accomplish this task. Sender: initial sequence number x ---> Receiver Sender: <--- ack sequence x+1, sequence number y: Receiver Sender: acknowledge sequence number y+1 ---> Receiver 3. Timeouts 4. Retransmission B. Flow Control Flow control is a mechanism which matches the rate of transmission by a sender to that of the receiver and/or the network. Goals: Fair, Simple and Stable 1. Closed Loop The source describes it's traffic characteristics to the network at "connection-time". The network can then reserve the necessary resources for the source traffic along the path. 2. Open Loop The source dynamically adjusts it's rate of flow to match its current share of the network. This can be done implicity or explicitly. 3. Hybrid A combination of open and closed loop flow control. For example, a station may reserve some minimum network resources, but then be allowed to use more resources as network resources become available. C. User Datagram Protocol UDP is a unreliable transport layer protocol. It's primary purpose is to provide simple application multiplexing to the TCP/IP protocol suite. Since applications do not run directly on top of IP, UDP provides the abstraction needed to run on top of IP with as little complexity and fuss as possible. Format of UDP message UDP source port (16) UDP destination port (16) UDP message length (16) UDP checksum (16) data (variable) Examples of UDP based applications: SNMP, RealAudio, TFTP, etc. D. Transport Control Protocol TCP provides reliability to applications. It does this by assuirng packets arrive without loss, duplication and mis-ordered. It enables reliability over a inherently unreliable IP network through the use of error control and flow control on an end-to-end basis. Format of TCP segment Source Port (16) Destination Port (16) Sequence Number (32) Acknowledgement Number (32) Header length (4) Reserved (6) Code bits (6) Window (16) Checksum (16) Urgent Pointer (16) Options (variable) Padding (if necessary) Data (variable) Packet Loss and Retransmission Through the use of timers and to windows, TCP will retransmit a packet that is not acknowledged. How long should TCP wait and how large should the window be? 1. Adaptive Retransmission 2. Three way handshake examples 3. Silly window syndrome and small packets 4. TCP flow control Rather than receiving specific congestion feedback from the network, TCP adjusts it's window size based on implicit signals received (packet loss). That is, the window is reduced when packet loss is detected, otherwise it is increased up to the maximum window size.