• No results found

IP Engineering Overview

N/A
N/A
Protected

Academic year: 2021

Share "IP Engineering Overview"

Copied!
294
0
0

Loading.... (view fulltext now)

Full text

(1)IP Engineering Overview. Wray Castle Limited Bridge Mills, Stramongate, Kendal, LA9 4UB, UK. [email protected] www.wraycastle.com © Wray Castle Limited all rights reserved.

(2)

(3) IP Engineering Overview. IP ENGINEERING OVERVIEW. First published 2003 Last updated December 2004 WRAY CASTLE LIMITED BRIDGE MILLS STRAMONGATE KENDAL LA9 4UB UK. Yours to have and to hold but not to copy The manual you are reading is protected by copyright law. This means that Wray Castle Limited could take you and your employer to court and claim heavy legal damages. Apart from fair dealing for the purposes of research or private study, as permitted under the Copyright, Designs and Patents Act 1988, this manual may only be reproduced or transmitted in any form or by any means with the prior permission in writing of Wray Castle Limited.. © Wray Castle Limited.

(4) IP Engineering Overview. ii. © Wray Castle Limited.

(5) IP Engineering Overview. IP ENGINEERING OVERVIEW. CONTENTS Section 1 Section 2 Section 3 Section 4. IP Networks Overview IP Network Services Service Provider Architectures Future Directions in IP Engineering. © Wray Castle Limited. iii.

(6) IP Engineering Overview. iv. © Wray Castle Limited.

(7) IP Engineering Overview. SECTION 1. IP NETWORKS OVERVIEW. © Wray Castle Limited. v.

(8) IP Engineering Overview. vi. © Wray Castle Limited.

(9) IP Engineering Overview. SECTION CONTENTS 1. Background to the Internet and ISPs 1.1 Internet History 1.2 Emergence of Commercial Operations 1.3 The Changing Architecture of the Public Internet 1.4 Internets, Intranets and the Internet 1.5 Service Providers (SPs). 1.1 1.1 1.3 1.3 1.5 1.5. 2. The Internet Paradigm 2.1 Switching Approaches 2.2 Circuit Switching 2.3 Packet Switching 2.4 Connectionless Versus Connection-Oriented Switching 2.5 How High-Functionality IP Networks Alter The Paradigm. 1.7 1.7 1.9 1.11 1.13 1.15. 3. Data Link Layer Protocols 3.1 The OSI and TCP/IP Protocol Stacks 3.2 The Role of L2 Protocols in the WAN 3.3 The Types of Layer 2 Switching 3.4 ATM as an L2 Switching Protocol for IP Traffic 3.5 Introduction to MPLS 3.6 MPLS as an L2 Switching Protocol 3.7 MPLS Forwarding Plane 3.8 MPLS Control Plane. 1.17 1.17 1.19 1.21 1.23 1.25 1.27 1.27 1.29. 4. The IP Layer 4.1 IP Datagram Forwarding 4.2 IP Address Classes 4.3 IP Subnet Masks 4.4 Network and Host Addresses 4.5 Control of IP Addresses 4.6 Network and Host Addresses 4.7 Subnetting IP Networks 4.8 Implementation 4.9 Classless Interdomain Routing (CIDR) 4.10 CIDR Example. 1.31 1.31 1.33 1.35 1.37 1.37 1.39 1.41 1.41 1.43 1.45. © Wray Castle Limited. vii.

(10) IP Engineering Overview. viii. © Wray Castle Limited.

(11) IP Engineering Overview. SECTION CONTENTS 5. The Transport Layer 5.1 Introduction 5.2 The Functions of Transmission Control Protocol (TCP) 5.3 The Functions of User Datagram Protocol (UDP). 1.47 1.47 1.49 1.51. 6. The Domain Name System (DNS) 6.1 The Role of the DNS 6.2 The Overall Architecture of the DNS 6.3 DNS Operation 6.4 Zones of Authority 6.5 Name Resolution 6.6 DNS Implementation 6.7 Types of DNS Server 6.8 Querying the Domain Name System. 1.53 1.53 1.55 1.57 1.57 1.59 1.61 1.63 1.65. 7. The Application Layer 7.1 Hypertext Transfer Protocol (HTTP) for Web Services 7.2 Simple Mail Transfer Protocol (SMTP) E-mail 7.3 POP3 and IMAP for E-mail Services 7.4 Post Office Protocol (POP) 7.5 Internet Message Access Protocol (IMAP4). 1.67 1.67 1.69 1.71 1.71 1.71. 8. Section 1 Questions. 1.73. © Wray Castle Limited. ix.

(12) IP Engineering Overview. x. © Wray Castle Limited.

(13) IP Engineering Overview. SECTION OBJECTIVES At the end of this section you will be able to: • • • •. explain the evolution of public service Internet Protocol (IP) networks compare and contrast the features of traditional data networks with IP networks explain the key functions of the IP network layer and IP addressing schemes describe the key transport and application-layer protocols of public service IP networks. © Wray Castle Limited. xi.

(14) IP Engineering Overview. 1. BACKGROUND TO THE INTERNET AND ISPS. 1.1. Internet History. In 1969, the Advanced Research Projects Agency (ARPA) funded a research and development project to create an experimental ‘packet switching’ network. This network was called ARPANET and was built in order to study techniques for the provision of a robust, reliable, vendor-independent data communications system. As a direct result of the success of ARPANET, many of the organizations involved in its development began to use it and, in 1975, the experimental network was converted into an operational one with the responsibility for it being given to the Defense Communications Agency (DCA). During this time, the early development of the basic Transmission Control Protocol/Internet Protocol (TCP/IP) took place. The TCP/IP protocols were adopted as Military Standards (MIL STD) in 1983, and all hosts that were to connect to the ARPANET were required to convert to these protocols. At the same time, the term Internet came into common use with the division of ARPANET into two new networks. These were MILNET, the unclassified part of the Defence Data Network (DDN), and a new, smaller ARPANET. The term ‘Internet’ was thus used to refer to the entire network, which comprised MILNET and ARPANET In 1985, the National Science Foundation (NSF) became involved by creating the NSFNet, which was connected to the Internet. The original NSFNet comprised five NSF super-computer centres, yet was still smaller than ARPANET and was restricted to data rates of only 56 kbit/s. However, the creation of NSFNet was a significant milestone in the development of the Internet as it brought a new vision of how the Internet should be used. The NSF wanted every scientist and engineer in the United States of America to be connected and, as such, they created a new, faster, backbone network that connected regional and local networks. In 1990, the ARPANET formally passed out of existence. NSFNet ceased its role as the primary Internet backbone network in 1995. In 1998, the Internet Corporation for Assigned Names and Numbers (ICANN) was established to take responsibility for Internet address management.. 1.1. © Wray Castle Limited. IP2300/S1/v2.1.

(15) IP Engineering Overview. 1969. –. Advanced Research Projects Agency fund research – ARPANET. 1975. –. Defense Communications Agency take responsibility TCP/IP development begins. – 1983. – –. TCP/IP protocols adopted as standard Internet formed – MILNET – ARPANET. 1985. –. National Science Foundation create NSFNet. 1990. –. ARPANET and NSFNet cease overall responsibility. 1998. –. Competition introduced with the establishment of ICANN. Figure 1 Internet Development IP2300/S1/v2.1. © Wray Castle Limited. 1.2.

(16) IP Engineering Overview. 1.2. Emergence of Commercial Operations. The original ARPANET and the successor NFSNET both operated Acceptable Use Policies (AUP) that did not permit commercial use of the network, and restricted traffic to research, educational and government use. Under pressure to make the Internet a commercial entity, the NSF managed a process of handing over responsibility for various functions to new commercial Service Providers (SPs) through the 1990s, including the backbone networks, the interconnect points and various registry functions. This new model specifically allowed commercial exploitation of the Internet, and as a result massive growth in the number of attached hosts and traffic carried has continued. In October 1998, competition was introduced in domain name registration for the toplevel domains. The Internet Corporation for Assigned Names and Numbers (ICANN) was established as a not-for-profit business to take responsibility for Internet address management, management of the Domain Name System (DNS), management of assigned numbers and operation of the Internet root servers. It achieves this through cooperation with organizations including the InterNIC, the Internet Assigned Numbers Authority (IANA) and Regional Internet Registries (RIR) that it has accredited.. 1.3. The Changing Architecture of the Public Internet. The single backbone approach of NFSNET was gradually replaced by a collection of commercial backbone providers such as Sprint and UUNet. Mergers and acquisitions in the last few years have left five major networks providing most transit within the global Internet. The number of SPs and their peering arrangements continues to grow and become more complex. The NSF interconnect points were replaced by Network Access Points (NAPs) within north America as part of the commercialization process. These provide a facility where networks can peer, managed by an independent third party. A large number of Internet eXchange Points (IXP) now operate on a commercial or cooperative basis, allowing smaller ISPs to peer on a regional basis.. 1.3. © Wray Castle Limited. IP2300/S1/v2.1.

(17) IP Engineering Overview. 1.7 x106. Hosts. The commercial Internet era. 200 4 1980. Time. Data >1,000,000,000,000,000 Bits/Day. Figure 2 Growth of the Internet IP2300/S1/v2.1. © Wray Castle Limited. 1.4.

(18) IP Engineering Overview. 1.4. Internets, Intranets and the Internet. The term internet was originally used to describe the network built upon the Internet Protocol (IP). However, the term is generic and is used to describe an entire class of networks. We will use the term ‘internet’ to mean any collection of separate physical networks, interconnected by means of the IP protocol, to form a single logical network. The ‘Internet’ is the worldwide collection of interconnected networks that grew out of the original ARPANET. It uses IP to link the various networks into a single logical global network. Since TCP/IP is required for Internet connection, the growth of the Internet has spurred interest in TCP/IP. More organizations have become familiar with the protocol suite and have applied it to many other applications. The IPs are now often used for local area networking even when the Local Area Network (LAN) is not connected to the Internet. In addition, TCP/IP is also widely used in building Enterprise Networks that use Internet techniques and World Wide Web (WWW) tools to disseminate internal corporate information. These networks are referred to as ‘intranets’ and may or may not be connected to the Internet.. 1.5. Service Providers (SPs). Private organizations obtain services on the public Internet through an SP. Internet Service Providers (ISPs) offer a range of services on the public Internet to their customers, such as dial-up access, and mail and web hosting. IP Service Providers (IPSPs) offer business-class IP networks to their customers. Rather than an open model of interconnection with other networks, where very few restrictions on traffic flows are applied, these networks connect with other networks in a much more controlled way. By keeping general Internet traffic off these networks, the quality of service they can offer to their directly connected customers is improved. These networks still require connectivity to the public Internet to allow Internet e-mail and other services.. 1.5. © Wray Castle Limited. IP2300/S1/v2.1.

(19) IP Engineering Overview. These connections allow Internet connectivity to IPSP customers. ISP 3. Three separate IP Service Providers. Internet. ISP 2 ISP 1. IPSP 3. IPSP 2. IPSP 1. This connection provides traditional Internet access. Network 1. Intranet. Network 2 Network 3. This connection gives the customer access to high functionality IP services. Figure 3 Intranets, ISPs and IP Service Providers IP2300/S1/v2.1. © Wray Castle Limited. 1.6.

(20) IP Engineering Overview. 2. THE INTERNET PARADIGM. 2.1. Switching Approaches. The two main switching approaches used in public switched networks are circuit switching and packet switching. Within packet switching, the switching process can be connection-oriented, or connectionless. Connection-oriented switching provides a logical circuit from source to destination, while a connectionless approach has no concept of a circuit. We explore these different types of switching in the next few slides.. 1.7. © Wray Castle Limited. IP2300/S1/v2.1.

(21) IP Engineering Overview. Public Switched Networks. Circuit Switched. Packet Switched. Physical circuit from source to destination. Virtual Circuit “connection-oriented”. Datagram “connectionless”. Logical circuit from source to destination. No concept of a circuit. Figure 4 Types of Switching IP2300/S1/v2.1. © Wray Castle Limited. 1.8.

(22) IP Engineering Overview. 2.2. Circuit Switching. Circuit switching involves a physical circuit being established between two given terminals for a period of time. The circuit is allocated to, and maintained for, the exclusive use of the terminals concerned for the whole duration of the connection. These resources only become available for use by other terminals upon release of the connection by the initial terminals. Circuit switching has several advantages. Firstly, the end terminals/devices/users are allocated the full data carrying capability (full bandwidth) of the connection for the whole duration of the call irrespective of whether they have data to send or not. In addition, although the initial routing process (or set-up) takes a period of time to be established at the switches, further data exchange via the switches is relatively short. This is because any further data exchange does not involve the analysis of addresses; instead the data simply flows through the provided physical connection. Finally, as all data for the connection takes the same physical route, the time taken for data to be transferred between terminals is kept nearly constant for the whole duration of the call. The disadvantage of circuit switching is that the initial set-up procedure takes time, as does the final release procedure. Also, should the network fail for any reason, the connection is lost completely and a new connection would need to be created. In addition, if the end terminals have a circuit-switched connection but no data to send, the end terminals will still hold the network resources unless they release the connection. In other words, the resources cannot be used by any other devices. This final fact is a disadvantage to both the user and the network operator. From the view of terminal owners it means that they are paying for a connection even though they may have no data to send; from the network operator’s view, it means that the network may have no resources available for users waiting to use the network. The advantages and disadvantages of circuit switching are highlighted in Figure 5. Although the two parties, A and C, are not presently speaking, network resources are still allocated to them. In addition, they are paying for call time. Parties B and D are unable to communicate with one another even though at that moment no meaningful data is being sent across the network. Circuit switching is important in IP engineering because dial-up access to various data networks is normally carried across a circuit-switched connection between the user and the location in the network where the data network is available.. 1.9. © Wray Castle Limited. IP2300/S1/v2.1.

(23) IP Engineering Overview. A. C. Sorry all the lines are busy. D. B. Circuit Switched Short Delay Constant Delay Single Connection Affected By Network Failure Figure 5 Circuit Switching IP2300/S1/v2.1. © Wray Castle Limited. 1.10.

(24) IP Engineering Overview. 2.3. Packet Switching. Packet switching involves the segmentation of users’ information into smaller blocks of data known as packets. Each packet is then fed into the network and passed from one switching point to the next until it reaches its destination. The network handles each packet separately therefore each must contain some control information to allow the forwarding process to take place at each switch. Packet switching has the advantage that each terminal to terminal exchange of data is not provided by a physical connection. Instead terminals share the network, each terminal being allocated network resources only as and when it has packets (or datagrams) to send. From the users’ point of view this is advantageous as they pay only for the data sent as opposed to time connected, i.e. users can be charged per packet as opposed to per second. From the network operator’s point of view packet switching allows all users to be given access to the network and also allows for more efficient dimensioning of the network. This final fact can lead to financial saving that can ultimately result in an even lower cost per packet for the user. In addition, as the network handles each packet separately, any failure within the network need not affect the transfer of packets itself. The network may simply route the packets via an alternative path so bypassing any failed elements. One disadvantage of packet switching is that the delay between a packet arriving at a switch and it being routed onwards may vary. This is because a packet switch may need to queue packets for sending onwards, the length of the queue varying with the number of packets involved with the onward leg.. 1.11. © Wray Castle Limited. IP2300/S1/v2.1.

(25) IP Engineering Overview. Packet Switched Long Delay Variable Delay Shared Resources Resilient to network failures. Figure 6 Packet Switching IP2300/S1/v2.1. © Wray Castle Limited. 1.12.

(26) IP Engineering Overview. 2.4. Connectionless Versus Connection-Oriented Switching. 2.4.1. Connectionless Services. Within the packet-switched network, packets can be forwarded through the network switches on a packet-by-packet basis. In other words, when a packet arrives at a switch or router, it reads the address information within the packet and then forwards the packet on to an appropriate destination based on forwarding tables within the switch. Once the packet has been sent, the switch or router sending it has no further dealings with the packet. Even packets that have arrived at the switch or router from the same source are treated individually. Because of this, there is no guarantee that packets sent by a single source will take the same path through the network, thus it is possible that packets could arrive at their destination out of sequence. In other words, the forwarding device makes no association between any packets that it receives or sends. When a network operates in this manner it is said to be providing a connectionless service to the users.. 2.4.2. Connection-Oriented Services. It is possible for a packet-switched network to provide what is termed a connectionoriented service to its users. When providing a connection-oriented service, information must first be passed across the network to set up a path for a user’s data. This path is termed a logical connection, virtual circuit or software-defined data path. The network then makes an association between all the packets sent from and to a specific user. This association allows the network to forward all of the packets for a specific user via the same path through the network, thus ensuring that packets arrive at the destination in the same order that they were sent. At the end of the data exchange, information is sent across the network to release the logical connection. This set-up and release of virtual circuits is analogous to setting up and releasing a physical circuit in circuit switching. Some delay is associated with these set-up and release operations. User packets cannot be forwarded until the virtual circuit has been set up. With a connection-oriented service, users appear to have their own connection through the network but it must be borne in mind that this is a logical connection only and that other users may use segments of the physical connection.. 1.13. © Wray Castle Limited. IP2300/S1/v2.1.

(27) IP Engineering Overview. Packet 1. Pa ck et. 2. Connectionless Service (packets may arrive out of sequence). Packet 2. Packet 1. Connection-Oriented Service (guaranteed sequenced delivery). Figure 7 Connectionless and Connection-Oriented Services IP2300/S1/v2.1. © Wray Castle Limited. 1.14.

(28) IP Engineering Overview. 2.5. How High-Functionality IP Networks Alter The Paradigm. The traditional best-endeavours model of IP networks and services is unsatisfactory for most business users. These users typically expect guarantees on network performance that a conventional IP network cannot provide. As a result, many of the techniques of connection-oriented packet-switched networks have been developed as optional components of IP networks, and are widely deployed in SP networks. Two or more Classes of Service (CoS) may be offered to customers, with different guarantees on performance for each of these. Traffic policing may be applied on the customer access circuit to ensure that the contracted data rates per CoS are not exceeded. Sophisticated queuing techniques may be applied in the network routers to implement the CoS behaviour expected by customers. Policy controls and route filtering may be applied to control how traffic is carried across the network, and how it enters and leaves the network. As well as measures at the IP layer, data link layer traffic engineering may be implemented to help control how traffic is carried, and more sophisticated restoration schemes may be implemented to ensure service outages are within acceptable limits to the customer. Therefore IP networks can broadly be categorized as: • Private enterprise networks (intranets) – these only carry the traffic of the owning organization. • Public, low functionality networks – these are typically part of the Internet structure, although they need not be. They carry traffic on a best-endeavours basis, and are offered by traditional ISPs. • Public, high functionality networks – these typically connect to the public Internet as well as to customer networks, but carefully control the traffic flows, types and utilization using the techniques outlined above. These networks are offered by IPSPs.. 1.15. © Wray Castle Limited. IP2300/S1/v2.1.

(29) IP Engineering Overview. Customer 2 Premises Router. Core Network Router Traffic policing ensures that only the contracted traffic quantity is accepted. QoS-aware queuing in core routers selects low priority traffic to drop, and protects high priority traffic. Customer 2 Premises Router. Best endeavours queuing in core routers causes high priority traffic to be dropped when congestion occurs. Overuse by one customer leaves other customers starved of bandwidth. Contention on customer access circuit causes high priority traffic to be dropped Customer 1 Premises Router. Customer Access Router. Diffserv CoS on access circuit protects high priority traffic. Customer Access Router. Customer 1 Premises Router. Core Network Router. Figure 8 Low- and High-Functionality IP Networks IP2300/S1/v2.1. © Wray Castle Limited. 1.16.

(30) IP Engineering Overview. 3. DATA LINK LAYER PROTOCOLS. 3.1. The OSI and TCP/IP Protocol Stacks. The OSI Seven-Layer Reference Model was developed before internetworking based upon the IP protocols became widespread. The developers of the TCP/IP suite produced a five-layer model, where the higher layers of the OSI model are collapsed into a single application layer. The TCP/IP model can be described as follows: Layer 1: Physical Layer Layer 1 deals with the physical network hardware just as Layer 1 in the OSI Seven Layer Reference Model. Layer 2: Link Layer Layer 2 protocols deal with how to organize data into frames and how a host transmits these frames over a network. Once again, these protocols are similar to the Layer 2 protocols in the OSI Seven-Layer Reference Model. Layer 3: Internet Layer Layer 3 protocols specify the format of the packets which are sent across the Internet as well as the mechanisms used to forward packets from a computer through one or more ‘routers’ to a final destination. Layer 4: Transport Layer Layer 4 protocols in the TCP/IP suite are similar to those in the OSI Seven-Layer Model in that they ensure reliable transfer of messages. Layer 5: Application Layer Layer 5 protocols in this model correspond to Layers 5, 6 and 7 in the OSI Model. These protocols specify how an application uses an internet. TCP/IP can, therefore, be looked upon as a family of protocols, each designed to solve a particular network communication problem.. 1.17. © Wray Castle Limited. IP2300/S1/v2.1.

(31) IP Engineering Overview. APPLICATION LAYER. OSI Layer 5–7. TRANSPORT LAYER. OSI Layer 4. INTERNET LAYER. OSI Layer 3. LINK LAYER. OSI Layer 2. PHYSICAL LAYER. OSI Layer 1. Figure 9 The TCP/IP Protocol Suite IP2300/S1/v2.1. © Wray Castle Limited. 1.18.

(32) IP Engineering Overview. 3.2. The Role of L2 Protocols in the WAN. The Link Layer in an IP network operates immediately below the IP layer, and so provides services to it. Whereas the IP layer is responsible for end-to-end transport of the data between hosts across the network, the link layer is responsible for transport on individual links of the network, between hosts and routers, and between intervening routers. Link layer protocols normally operate in one of three modes: • connectionless, across a point-to-point connection • connectionless, across a shared medium • connection-oriented, across a virtual circuit-switched network. 1.19. © Wray Castle Limited. IP2300/S1/v2.1.

(33) IP Engineering Overview. Router. Ethernet. Router. ATM. Token Ring. IP (Layer 3) Ethernet (Layer 2). ATM (Layer 2). Token Ring (Layer 2). Connectionless (point-to-point). Connectionless (shared medium). Connection-oriented (virtual circuit network) Figure 10 The Role of Layer 2 Protocols IP2300/S1/v2.1. © Wray Castle Limited. 1.20.

(34) IP Engineering Overview. 3.3. The Types of Layer 2 Switching. It is important to understand the distinction between connection-oriented and connectionless Layer 2 networks, as this affects how IP operates across them. When a traditional shared medium network such as Ethernet is partitioned using Ethernet switching, the complete network retains the ability to broadcast frames, because ‘Ethernet’ is a connectionless switching technology. The IP layer uses these broadcast frames to discover the address mapping between the IP layer and the connectionless Layer 2 addresses of hosts and interfaces. The use of switches can improve the performance of ‘Ethernet’ by reducing the number of hosts that share a particular medium. However, this is still connectionless switching, and still retains the ability to use broadcast frames across the entire switched network. Connection-oriented Layer 2 networks use virtual circuits to connect hosts. They have no ability to send packets to a destination address until the Layer 2 address of the destination is known. Therefore, conventional IP techniques for address resolution between the IP and Layer 2 addresses are not available. Although these connection-oriented Layer 2 technologies are more scalable than the connectionless approaches, the lack of broadcast makes interworking with IP networks more difficult.. 1.21. © Wray Castle Limited. IP2300/S1/v2.1.

(35) IP Engineering Overview. Router. Ethernet. Router. ATM. Token Ring. IP (Layer 3) Ethernet (Layer 2). ATM (Layer 2). Token Ring (Layer 2). Connectionless (point-to-point). Connectionless (shared medium). Connection-oriented (virtual circuit network) Figure 10 (repeated) The Role of Layer 2 Protocols IP2300/S1/v2.1. © Wray Castle Limited. 1.22.

(36) IP Engineering Overview. 3.4. ATM as an L2 Switching Protocol for IP Traffic. ATM is a Layer 2 switching technology that is widely used in public service networks¹. The architectures of IP and ATM are quite different, with different addressing schemes, forwarding approaches and control planes. Therefore little integration between the IP layer and the ATM layer is possible. Nonetheless, ATM is widely used as a Layer 2 switching technology to carry IP traffic. Typically a set of ATM virtual circuits is established between edge routers, either through signalling, or more usually by configuration from a Network Operations Centre (NOC). Viewed from the perspective of the IP layer, these virtual circuits are simply virtual leased lines that connect adjacent routers. The IP layer has no visibility of the intervening switches. IP views the ATM protocol as just another encapsulation, similar to HDLC or PPP. In order to route traffic correctly to the other routers across the ATM Wide Area Network (WAN), each edge router must either have static routes configured which point traffic to the correct outbound virtual circuit, or else a conventional routing protocol must run across the WAN between edge routers.. ¹ Instead of variable length frames, ATM uses short, fixed-length cells to transport traffic across the network, since this makes delay and delay variation smaller and more predictable. To convert various types of traffic into cell payloads, ATM requires the use of adaptation functions at the edge of the network. As well as adding any ATM-specific headers or trailers required, the ATM adaptation process segments inbound traffic into cell payloads, and reassembles the original data structures for outbound traffic. Despite this unique aspect of ATM, it can still be considered as a Layer 2 switching technology; the adaptation process is hidden from the IP layer above it.. 1.23. © Wray Castle Limited. IP2300/S1/v2.1.

(37) IP Engineering Overview. Router. 1. Establish ATM virtual circuit between pairs of routers 2. Routers are adjacent at the IP layer, see ATM network as a virtual leased line. IP. IP. Ether. ATM. ATM. ATM. Phys. Phys. Phys Phys. Phys Phys. ATM Phys. Ether Phys. Figure 11 Simple IP Over ATM IP2300/S1/v2.1. © Wray Castle Limited. 1.24.

(38) IP Engineering Overview. 3.5. Introduction to MPLS. Traditionally, switches have offered greater performance than routers in terms of the speed at which data can be forwarded. However, routers can be configured to make more sophisticated decisions about the processing of datagrams. As well as forwarding a packet based upon destination IP address, a router can also classify packets based upon other header fields, including source address and TCP port numbers. This leads to the argument, why not build a device that combines fast forwarding across the core of a network, based upon classification of packets carried out at the edge of the network? While this is essentially what an IP over ATM approach achieves, the key innovation of the MPLS approach was the use of traditional IP routing protocols to determine how these switched paths should be set up. For the first time in MPLS, a switching model closely coupled to the IP layer it was intended to support was available. The argument leads to the idea of Label Switching Routers (LSR), devices that integrate the best of both routing and switching. Whereas traditional Layer 2 switching was not integrated with the IP layer, MPLS is closely coupled to the routing and addressing schemes of the IP layer.. 1.25. © Wray Castle Limited. IP2300/S1/v2.1.

(39) IP Engineering Overview. Router. Switch. Sophisticated Routing Layer 3. Fast Switching Layer 2. V Connectionless. Connection-Oriented. MPLS. LSR Integration of Routing and Switching. Figure 12 MPLS Combines Routing and Switching IP2300/S1/v2.1. © Wray Castle Limited. 1.26.

(40) IP Engineering Overview. 3.6. MPLS as an L2 Switching Protocol. There are many similarities between the switching and forwarding operations of LSRs and the switching and forwarding of traditional Layer 2 switching technologies, such as Frame Relay and ATM. MPLS introduces some new terminology for Layer 2 switching: • a Label Switching Router (LSR) is an MPLS Layer 2 switch • a Label Switched Path (LSP) is an end-to-end MPLS virtual connection • an edge-LSR is a special LSR that originates or terminates LSPs, and can classify IP traffic for forwarding across the best LSP • a Forwarding Equivalence Class (FEC) is a grouping of IP addresses that are treated identically by the LSRs, and are forwarded along a common LSP. 3.7. MPLS Forwarding Plane. The MPLS forwarding plane can operate on individual packets arriving at an edgeLSR once an appropriate LSP has been set up. When a packet arrives at the ingress edge-LSR, this router determines the outgoing port and FEC. On the assumption that LSPs have been set up, the edge-LSR will be able to identify the label to be used for the ongoing port and FEC. The edge-LSR appends this label to the received packet and passes this out over the designated port. The LSR receiving the MPLS packet on a given port will look up the incoming port and label entry within its Label Information Base (LIB). This will produce an outgoing port and label result. The incoming MPLS packet will then have its label swapped for the new label and is then passed out over the outgoing port (with this new label). The LSR within the MPLS network (as opposed to the edge-LSR) therefore need operate at Layer 2 only. All LSRs within the MPLS network operate in this manner until the packet arrives at the egress LSR. At the egress LSR, the MPLS label is removed, the packet is passed to Layer 3, and is then routed in the normal router manner. In essence, MPLS allows Layer 3 processing to be pushed to the edge of the MPLS network.. 1.27. © Wray Castle Limited. IP2300/S1/v2.1.

(41) IP Engineering Overview. Downstream IP Packet. MPLS Network. Header A. M. IP Packet. S PL. Pa. La. Labe lC. cket MPL. S Pa. Performs Label Swapping. Upstream. IP. MPLS Packet. et ck. Label B. lA be. Header A. IP. LSR. edge-LSR. edge-LSRs LSRs. Both operate at L2 and L3. Figure 13 MPLS Forwarding of Packets IP2300/S1/v2.1. © Wray Castle Limited. 1.28.

(42) IP Engineering Overview. 3.8. MPLS Control Plane. ATM and Frame Relay use a development of traditional ISDN signalling protocols to set up, tear down and manage virtual circuits. This is known as a data driven approach. MPLS generalizes this approach, and allows LSPs to be set up in several different ways: • by extensions to traditional IP routing protocols such as Border Gateway Protocol (BGP) • by a specialized IP signalling protocol, Resource Reservation Protocol (RSVP) • by a dedicated label distribution protocol operating between LSRs, Label Distribution Protocol (LDP) However the LSPs are set up, once they are in place, the forwarding and switching operations carried out by LSRs are identical.. 1.29. © Wray Castle Limited. IP2300/S1/v2.1.

(43) IP Engineering Overview. 1. Extensions to BGP protocol carry LSP information between LSRs. MPLS Network. 2. RSVP protocol used to signal the set-up of LSP, as required by data flows 3. LDP protocol distributes LSP information between adjacent LSRs IP Packet. LSR. edge-LSR. edge-LSRs LSRs. Both operate at L2 and L3. Figure 14 MPLS Control Plane Options IP2300/S1/v2.1. © Wray Castle Limited. 1.30.

(44) IP Engineering Overview. 4. THE IP LAYER. 4.1. IP Datagram Forwarding. Because IP networks operate a connectionless forwarding model, the routers hold no information about the flow of packets; the routing decision is made independently for each packet arriving at each router along its path. The router makes this decision by comparing the destination address of an incoming packet with the entries already held in its routing table. The most specific match in the routing table to the destination address is used to find the next hop for this packet. We can see from Figure 15 that the routing table contains three parameters: a Destination field, which contains network addresses, an Address Mask that specifies which bits of the destination correspond to the network ID, and finally a Next Hop field, which contains the IP address of the router if required. For example, if we consider a datagram designed for address 192.4.10.3 and assume the datagram arrives at router 2, which contains the routing table shown in Figure 16, the router software will sequentially search the routing table.. 1.31. © Wray Castle Limited. IP2300/S1/v2.1.

(45) IP Engineering Overview. 30.0.0.0. 40.0.0.7. Router 30.0.0.7 #1 40.0.0.0 128.1.0.8 40.0.0.8. Router #2. 128.1.0.0 192.4.10.9. 192.4.10.0. Router 128.1.0.9 #3. 192.4.10.3. Destination 30.0.0.0 40.0.0.0 128.1.0.0 192.4.10.0. Next Hop 40.0.0.7 Direct Direct 128.1.0.9. Simplified Routing Table For Router #2. Figure 15 IP Datagram Forwarding IP2300/S1/v2.1. © Wray Castle Limited. 1.32.

(46) IP Engineering Overview. 4.2. IP Address Classes. The problem with using an IP Address containing network IDs and host IDs is deciding how big to make each field. If the network ID field is too small (limited permutations), only a few networks will be able to be connected to the Internet and still ensure that each has a unique address; yet should the network ID field be increased, then the host ID will have to be reduced and only a few computers will be able to be connected to a particular network with a given network ID. As an internet is likely to include various types of network technologies, one given structure of an IP Address is not appropriate. The developers of IP therefore chose a compromise in the IP addressing scheme that is able to accommodate both large and small networks. This scheme divides the IP Address (32 bits) into three primary classes where each class has a different-size network ID and host ID. The first four bits of an IP Address determine which class the address belongs to, and how much of the remainder of the 32 bits have been divided into network and host addresses. Although IP Addresses are 32 bits in length, they are seldom represented in binary format but instead use a dotted decimal notation. This method of representation takes the four 8-bit sections (octets) and represents each as a decimal number. The ‘.’ sign is used to separate each of the four decimal numbers. For example, the 32-bit binary code: 10000100. 00110000. 00000110. 00000000. has the dotted decimal notation: 132.48.6.0 Since each octet can have a maximum decimal value of 255, IP addresses can range from: 0.0.0.0 to 255.255.255.255. 1.33. © Wray Castle Limited. IP2300/S1/v2.1.

(47) IP Engineering Overview. 32 bits Network ID. Class B. Example. Host ID. A .. B. .. C. .. D. 132 .. 48. .. 6. .. 0. Class A Network ID. Host ID. 0. Class B Network ID. Host ID. 1 0. Class C Network ID. Host ID. 11 0. Class D Multicast 11 1 0. Class E Experimental 1 11 1. Figure 16 IP Address Classes IP2300/S1/v2.1. © Wray Castle Limited. 1.34.

(48) IP Engineering Overview. 4.3. IP Subnet Masks. A subnet mask is applied to the IP address to determine which part of the 32-bit address makes up the network address, and which part constitutes the host address. Figure 17a shows the default subnet masks for Class A, B and C networks, and Figure 17b shows how it is applied to a Class B network. When sending packets, a host or router needs to determine if the IP address of the destination host is on the local or a remote network. When TCP/IP initializes, the host’s IP address is ANDed with its subnet mask, and the result stored. When sending data to another host the destination IP address is also ANDed with the local host’s subnet mask. If the resulting values match (see Figure 17c), the destination host is on the local network; if not, the datagram is sent to the source host’s default router.. 1.35. © Wray Castle Limited. IP2300/S1/v2.1.

(49) IP Engineering Overview. Default Subnet Masks Address Class. Bits used for Subnet Mask. Class A. 11111111. Class B. 11111111. 11111111. Class C. 11111111. 11111111. Dotted Decimal Notation. 00000000 00000000 00000000. 255.0.0.0. 00000000 00000000 11111111. 255.255.0.0. 00000000. 255.255.255.0. Figure 17a Example of a Class B Subnet Mask. IP Address. 132. .. 48. .. 6. .. 0. Subnet Mask. 255. .. 255. .. 0. .. 0. Network ID. 132. .. 48. .. x. .. x. Host ID. x. .. x. .. 6. .. 0. Figure 17b Determination of a Packet’s Destination. Destination Hosts IP Address is ANDed with local Subnet Mask • 1 AND 1=1 • Other Combinations = 0 • If ANDed results of source and destination hosts match, the destination is local. IP Address Subnet Mask Result. 10000100. 00110000. 00000110. 00000000. 11111111. 11111111. 00000000. 00000000. 10000100. 00110000. 00000000. 00000000. 132. •. 48. •. 0. •. 0. Figure 17c IP Subnet Masks and Determination of a Packet’s Destination IP2300/S1/v2.1. © Wray Castle Limited. 1.36.

(50) IP Engineering Overview. 4.4. Network and Host Addresses. Relating the dotted decimal notation method to the different classes of IP address, we can see that first octet will carry the information necessary to determine the IP class of the host. The IP class scheme does not divide the 32-bit address space into equal size classes and these classes do not contain equal numbers of networks. For example, half of all IP addresses lie within Class A, as this class is represented by a zero in the first bit position. Therefore, since Class A addresses only have eight bits to represent the network ID and one of these is used to indicate this is an A class address, there only remain seven bits to indicate the network. In other words, a Class A address can only account for a maximum of 128 different networks. However, the host ID in a Class A address is made up of 24 bits, which allows up to 16,777,216 computers to be connected to each of the 128 networks.. 4.5. Control of IP Addresses. As we have already determined, each network ID must be unique and as such all networks connecting to the global Internet must have their own unique network address. Therefore, if an organization wishes to connect its network to the Internet, it must obtain a network address from an ISP. The ISPs obtain network numbers through a system of approved Internet registries, who ensure that numbers are globally unique. In the case of a private internet (intranet), the choice of the IP Address can be made by the organization, although no two computers may have the same address. It is difficult and time-consuming to renumber a large IP network, and historically problems have occurred when private IP networks have subsequently connected to the public Internet, and found that address conflicts occurred. For this reason, a group of class A, B and C addresses were reserved for private use in RCF 1918, and organizations often use these addresses for private IP networks, whether connected to the public Internet or not.. 1.37. © Wray Castle Limited. IP2300/S1/v2.1.

(51) IP Engineering Overview. Class. Range of Values. A B C D E. 0 – 127 128 – 191 192 – 223 224 – 239 240 – 255. Figure 18a IP Address Classes and Dotted Decimal Notation. Address Class. Bits in Prefix. Maximum number of Networks. Bits in Suffix. Maximum number of Hosts per Network. A B C. 8 16 24. 126 16382 2097150. 24 16 8. 16777214 65534 254. Figure 18b Network/Host Numbers IP2300/S1/v2.1. © Wray Castle Limited. 1.38.

(52) IP Engineering Overview. 4.6. Network and Host Addresses. In summary, when assigning a network ID, a number must be selected from either Class A, B or C depending upon the size of the physical network. In real terms, a network will be assigned a Class C address ((256 – 2) hosts per network) unless a Class B is needed ((65,536 – 2) hosts). Class A addresses are seldom assigned. Figure 19 shows a possible configuration when connecting four networks together; a small network (Class C), two medium size networks (Class B), and one large network (Class A). Thus, the four networks may have the following IP Addresses: Class A. 11.0.0.0. Class B. 128.270.0 145.56.0.0. Class C. 195.34.127.0. Note: IP reserves the host address set to zero and uses it to denote the network address. Likewise the all 1s host address is used for broadcasts to all hosts. These addresses cannot be assigned to any host on that particular network. As we can see, all host computers connected to each network carry the same network ID. However, the host ID will be different for each of the hosts connected to that network.. 1.39. © Wray Castle Limited. IP2300/S1/v2.1.

(53) IP Engineering Overview. 128.27.0.18. 195.34.127.13. router 195.34.127.48. Prefix =128.27. ‘C’. ‘B’. Prefix = 195.34.127. 128.27.0.19. 145.56.74.118. ‘A’ ‘B’ Prefix = 10 Prefix = 145.56. 10.18.74.15 145.56.19.4. 10.0.127.16. Figure 19 Example Network with IP Addressing IP2300/S1/v2.1. © Wray Castle Limited. 1.40.

(54) IP Engineering Overview. 4.7. Subnetting IP Networks. The traditional boundaries of class A, B and C networks are too inflexible in many real networking situations. An organization might have, for example, a class B network that it wants to partition to allow separate administration of the subnetworks, or to impose policy controls on which traffic can flow between subnets. This partitioning is done by subnetting the original address space. A unique subnet ID is derived for each segment by partitioning the bits in the host ID into two parts. One part is used to identify the segment as a unique network, and the other part is used to identify the hosts. The total number of networks bits in the address is the sum of the original network part and the subnet part. It is indicated by a value given after the address. So, for example, the private class C address 192.168.1.0/24 might be subnetted by using an additional five host bits to create a set of smaller subnets from the original space, each of the form 192.168.1.x/29. Some implementations disallow the lowest and highest valued subnet, because they contain the original network address and broadcast address of the classful network. In this case the total available subnets are reduced by two. It is important to note that this subnet structure does not propagate beyond the local network boundary. Therefore as traffic enters the public Internet from such a subnetted structure, all of the subnets are summarized into a single, class-based routing announcement.. 4.8. Implementation. Before subnetting is implemented, the current and future requirements of the network need to be considered. This should include the number of physical segments that will be required and the number of hosts on each segment. (It should be noted that hosts include routers). Based on requirements, if possible one subnet mask should be defined for the entire network, with a unique subnet ID for each segment and a range of host IDs for each subnet. When more bits are used for the subnet mask, more subnets are available, but fewer host addresses are available per subnet. A balance has to be reached between leaving room for the network to grow, and allowing sufficient hosts on each subnet. In some cases, the number of hosts required on each subnet is uneven. A particular subnet may need perhaps 100 host addresses, while a WAN link may require only two addresses. In this case, Variable Length Subnet Masks (VLSM) can be used to partition the available space efficiently.. 1.41. © Wray Castle Limited. IP2300/S1/v2.1.

(55) IP Engineering Overview. /29. 8.0.8 6 1 . 192. 192.168.0.16/29. 192.168.0.0/24. 192. 168. 0. .24/2. 9. Traditional Class C address has: 28 – 2 host addresses X.X.X.0. = network address. X . X . X . 255 = broadcast address X.X.X.1 = host address space X . X . X . 254. Subnetting on /29 boundary X . X . X . nnnnnhhh Each subnetwork has: 23 – 2 host addresses = 6 host addresses Total number of subnets is: 25 – 2 = 30 subnets Figure 20 An Example of IP Subnetting IP2300/S1/v2.1. © Wray Castle Limited. 1.42.

(56) IP Engineering Overview. 4.9. Classless Interdomain Routing (CIDR). Subnetting allows more efficient use of a traditional class-based IP network within an organization, by allowing it to be subdivided. However traditional subnetting does not propagate through the Internet routing tables, because routes are summarized back to their classful form at the administrative boundary of the network. Therefore Internet routing tables in this model must contain separate routes for each assigned class A, B or C address. In the mid-1990s, the size of Internet routing tables was growing massively, to the point where performance of the backbone networks was affected. It was realized that much of the fine-grained detail in Internet routing tables was redundant, and that a more flexible hierarchy should be imposed, by allowing routes for smaller networks to be aggregated together before they were advertised into the public Internet. This also allows more efficient use of available IP addresses by allocating blocks of class C addresses rather than a single class B, and by subnetting class A and B networks into smaller allocations, rather than offering an entire classful network to an enterprise. CIDR is essentially a generalization of the subnetting concept². To make CIDR effective, it was necessary to impose some geographical structure on the IP address space, so that aggregation could be as effective as possible. As a result of a policy change, IP addresses are now assigned in blocks through a hierarchy of SPs. In general, large blocks of IP addresses are allocated to regional registries, which will in turn assign smaller blocks of address space to SP, which will in turn assign yet smaller blocks to ISP. Finally, individual users will rent IP addresses from their respective ISP.. ² CIDR allows larger networks to be subdivided, and smaller networks to be aggregated together into a single routing table entry, in a flexible way, by using VLSM. By carrying these VLSM values in routing protocol updates, and within routing tables, it allows the VLSM structure to propagate across the Internet between domains, instead of reverting to classful networks at the boundaries, according to the original subnetting model.. 1.43. © Wray Castle Limited. IP2300/S1/v2.1.

(57) IP Engineering Overview. Block A. Block B. A. IANA and IR. B. Sub Blocks of B. Sub Blocks of A. Major ISP. Smaller ISP. Smaller ISP. Users Leased IP Addresses. Area. Address. Multiregional Europe Others North America Central/South America Pacific Rim Others Others. 192.0.0.0-193.255.255.225 194.0.0.0-195.255.255.225 196.0.0.0-197.255.255.225 198.0.0.0-199.255.255.225 200.0.0.0-201.255.255.225 202.0.0.0-203.255.255.225 204.0.0.0-205.255.255.225 206.0.0.0-207.255.255.225. Reference. RFC 1518. Figure 21 IP Address Blocks IP2300/S1/v2.1. © Wray Castle Limited. 1.44.

(58) IP Engineering Overview. 4.10. CIDR Example. A common use of both subnetting and CIDR occurs where an SP wants to offer a few public network IP addresses to a small business network, for example as part of a business ADSL offering, where the customer may host some servers at their premises. In the example shown in Figure 22, the SP has subnetted a class C address into 30 subnets, each with 6 host addresses, by subnetting at the /29 boundary. The detail of one such subnet is shown, where the subscriber has 5 host addresses available, in addition to the IP address needed for the ADSL router on the customer premises. In total 120 customer subnets are available from the 4 class C addresses shown. Within the SP network, rather than advertise the individual class C addresses, instead it aggregates 4 networks into a new /22 route advertisement, and passes this into the Internet routing tables. In this example, traffic for all of the customer networks shown would be represented by a common /22 routing entry within the Internet until it reached the SP network. Individual /24 routing table entries in router A would direct it to the correct customer access router, in our example router B. Router B would then direct traffic to the correct customer network using /29 entries in its routing table.. 1.45. © Wray Castle Limited. IP2300/S1/v2.1.

(59) IP Engineering Overview. Routers. CIDR route aggregation at this layer, beyond the conventional Class C boundary. 0/ .3.. 24. 8 .16 2 19 24 2.0/ . 8 6 1 192.. RA. 192.168.1.0/24. 192.168.0.0/22. Routers. Routed on /22 /24 .0.0 .168 /24 192 on ted Rou. RB. 32 .0.. /29. 4 .16 8 19 /29 0.24 . 4 6 1 198.. 198.164.0.16/29 Routed on /29. 8 19. .18. 64 .1. .20 .19. .0 .8. .22 .21. /2 9. Route summarization up to conventional Class C boundary at this layer. .17. Figure 22 An Example of CIDR IP2300/S1/v2.1. © Wray Castle Limited. 1.46.

(60) IP Engineering Overview. 5. THE TRANSPORT LAYER. 5.1. Introduction. The transport layer of the TCP/IP Protocol Suite comprises two protocols: Transmission Control Protocol (TCP) and User Datagram Protocol (UDP). Fundamentally, the services offered by TCP are reliable and connection-oriented, whereas UDP provides a best efforts, connectionless service.. 1.47. © Wray Castle Limited. IP2300/S1/v2.1.

(61) IP Engineering Overview. APPLICATION LAYER OSI Layer 5–7. Transmission Control Protocol. Internet Control Messaging Protocol. Internet Protocol. User Datagram Protocol. Address Resolution Protocol. TRANSPORT LAYER OSI Layer 4. INTERNET LAYER OSI Layer 3. Link Layer Protocols. LINK LAYER OSI Layer 2. Physical Networks. PHYSICAL LAYER OSI Layer 1. Figure 23 TCP/IP Suite IP2300/S1/v2.1. © Wray Castle Limited. 1.48.

(62) IP Engineering Overview. 5.2. The Functions of Transmission Control Protocol (TCP). The Transmission Control Protocol (TCP) provides a highly reliable transport service. Applications such as FTP and HTTP that require reliable transport services use the TCP protocol. TCP offers several key features as shown below.. 5.2.1. Connection-Oriented. TCP provides a connection-oriented service in which an application must first establish a connection to the destination before any data is transferred. TCP requires that both applications creating a connection agree to the new connection.. 5.2.2. Error Control. TCP ensures that data sent across a connection is error free and in the correct sequence. It does this by including sequence numbers within the protocol header, and requesting retransmission of lost or corrupted packets.. 5.2.3. Flow Control. TCP measures the throughput of traffic between TCP applications, and tries to maximise the bandwidth available. When packets are lost in transit, TCP assumes this is due to congestion, and slows down its transmission rate. When packets are arriving successfully, TCP assumes more bandwidth is available, and increases its transmission rate. In this way, TCP is always trying to get the maximum available bandwidth from the network.. 5.2.4. TCP Port Addressing. Within an IP network, data is routed according to its IP address, with no distinction made regarding the user or process on the destination host. The Transport Layer extends the TCP/IP protocol suit to distinguish between applications on a given host. These ports are known as ‘Protocol Ports’ and can be addressed using the 16 bits in the Source and Destination Port address fields. These 16 bits can describe 65,536 possible ports on the host.. 1.49. © Wray Castle Limited. IP2300/S1/v2.1.

(63) IP Engineering Overview. Connection-oriented Error control Flow control Source and destination ports. 7 0 1 2 3. 6. 5. 4. 3. 2. 1. 0. - bits. Source Port Destination Port. 4 5. Sequence Number. 6 7 8 9. Acknowledgement Number. 10 11 12. Data Offset. Reserved. 13. Reserved URG ACK. PSH RST SYN FIN. 14 15 Octets. Window. 16 17 18. Checksum Urgent Pointer. 19 20 21. Options (Optional). 22 23. Padding. Figure 24 TCP Functions IP2300/S1/v2.1. © Wray Castle Limited. 1.50.

(64) IP Engineering Overview. 5.3. The Functions of User Datagram Protocol (UDP). User Datagram Protocol (UDP) provides Application Layer Services with a transaction-oriented, datagram-type service that is connectionless and unreliable. It is a simple and efficient protocol that is stateless, and so ideal for such applications as Trivial File Transfer Protocol (TFTP), Simple Network Management Protocol (SNMP) and queries to the Domain Name System (DNS). The UDP protocol is extremely simple, and this is reflected in the protocol fields of UDP. As for TCP, the UDP protocol carries source and destination port values, so that traffic can be directed to the correct applications on machines running multiple simultaneous sessions. The Checksum field allows corrupted data to be detected and (silently) discarded, but UDP does not have the error recovery mechanisms of TCP. Responsibility for error recover lies with the higher layer protocol that is using the UDP service in this case.. 1.51. © Wray Castle Limited. IP2300/S1/v2.1.

(65) IP Engineering Overview. Connectionless No error control No flow control Source and destination ports. Bits 7 Octets. 6. 5. 4. 3. 2. 1. 0. 0 Source Port 1 2 Destination Port 3 4 Message Length 5 6 Checksum 7. Figure 25 UDP Functions IP2300/S1/v2.1. © Wray Castle Limited. 1.52.

(66) IP Engineering Overview. 6. THE DOMAIN NAME SYSTEM (DNS). 6.1. The Role of the DNS. To a human, identifying hosts on a network by their IP address is not easy. IP addresses are difficult to remember and do not convey any meaning about the respective host. Humans find it far easier to remember names, and if the name indicates the role of the host, it can also be used to convey meaning. In the 1980s there were only a few hundred hosts on the ARPANET. The computer name-to-IP mapping was held in a single file called Hosts.txt on a server at the Stamford Research Institute Network Information Centre (SRI-NIC). This was manually updated. If details of a host changed, the SRI-NIC was called and asked to change the file. As the network grew this system became too difficult to administer. DNS was designed as a distributed database using a hierarchical name structure to overcome this problem.. 1.53. © Wray Castle Limited. IP2300/S1/v2.1.

(67) IP Engineering Overview. Root. Domain. Sub-Domain. Domain. Sub-Domain. Domain. Sub-Domain. Figure 26 Domain Name System (DNS) IP2300/S1/v2.1. © Wray Castle Limited. 1.54.

(68) IP Engineering Overview. 6.2. The Overall Architecture of the DNS. The root domain of the Internet is represented by a single period (.), and the Internet Corporation for Assigned Numbers (ICANN) manages the operation of the root servers that resolve for all domains beneath the root. Beneath this root are the Top Level Domains (TLDs) that may be global or contain a country code (ccTLDs). Some examples of these domains, and their intended use, is given in Figure 27, and described below: com Commercial organizations such as: America OnLine (aol.com), British Telecom (bt.com) and Wray Castle (wraycastle.com) edu Educational institutions (namely colleges and universities in USA) net Networking organizations such as the central network concerning the Internet, i.e. InterNIC (Internet Network Information Centre) – internic.net org Non-commercial organizations such as the Internet Engineering Task Force (IETF) at ietf.org Recently some new TLDs have been created, including the .biz TLD, which is intended to be broadly equivalent to the popular .com domain. As might be expected, the Internet namespace is extremely inefficient, with even very small businesses wanting a second level domain. Overall control of the Domain Name System is within ICANN. The central IR is held on INTERNIC.NET, which is in North America and is responsible for networks in this area and other unspecified parts of the world. Europe and Asia-Pacific are two specified areas and as such have their own registries. These are RIPE NCC (or ripe.net) and APNIC (or apnic.net) respectively.. 1.55. © Wray Castle Limited. IP2300/S1/v2.1.

(69) IP Engineering Overview. root. .biz. .com. wraycastle.com. .edu. .net. .org. telecoms-engineering.net. .uk. .co.uk. .ac.uk. wraycastle.co.uk. Figure 27 The Hierarchy of the Internet DNS IP2300/S1/v2.1. © Wray Castle Limited. 1.56.

(70) IP Engineering Overview. 6.3. DNS Operation. The DNS is a client/server-distributed database management system. The client is known as the ‘Resolver’. It passes name requests that contain queries to a server known as the ‘Name Server’. These name servers are grouped into logical levels known as ‘Domains’. DNS is analogous to a telephone book. You look up the name of the person you want to call, and read across to get the telephone number. Using DNS, the resolver passes the name to the name server who runs a query on the database to return the IP address. The host name queried must be in the form of a Fully Qualified Domain Name (FQDN).. 6.4. Zones of Authority. The implementation of the DNS uses the concept of Zones of Authority to make administration of the hierarchy easier. The zone of authority is the portion of the domain for which a particular primary name server is responsible. It stores all mappings for the zone and answers queries for those names. The name server’s zone of authority covers at least one domain, known as the zone root domain. The zone of authority may also cover sub-domains. The zone does not necessarily cover all the sub-domains under the root domain, but the zone must be contiguous. So in the example shown, the zone one database does not contain name-to-IP address mapping for machines in the sales domain, although the sales domain is a sub-domain of the wraycastle domain. A single DNS server can be configured to manage one or more multiple zone files.. 1.57. © Wray Castle Limited. IP2300/S1/v2.1.

(71) IP Engineering Overview. .com. wraycastle.com. zone 1 database. zone 2 database. development.wraycastle.com. sales.wraycastle.com. Figure 28 DNS Zones of Authority IP2300/S1/v2.1. © Wray Castle Limited. 1.58.

(72) IP Engineering Overview. 6.5. Name Resolution. The operation of a DNS query to resolve the IP address of a web server within an example domain, ‘wraycastle.com’, is shown in Figure 29. 1. The client sends a query to its local name server, requesting the IP address of www.wraycastle.com.. 2. The local name server checks its zone for the name www.wraycastle.com. It then sends an iterative query for this name to the root server.. 3. The root server has authority for the root domain and will reply with the IP address of the .com top-level domain. It returns this to the local server.. 4. The local server sends an iterative query to the .com name server for www.wraycastle.com. The name server responds with the IP address of the wraycastle.com name server.. 5. The local server sends an iterative query to the wraycastle.com name server for the full address. The wraycastle.com server sends the IP address of www.wraycastle.com back to the local server.. 6. The local server sends the IP address for www.wraycastle.com back to the original resolver.. 1.59. © Wray Castle Limited. IP2300/S1/v2.1.

(73) IP Engineering Overview. 2.. se me na. re. fer. .com name server. 3.. req. ue s. ta. dd. to .. res. co. m. sw. ww .w ray ca. stl. rv er. e.c om. root name server. 4. reque. Local name server. refe. st addre. am e.com n l t s a c y r to wra. 5. r e qu est. RE. SP. ON S. E=. 6. Answer: The IP address of www.wraycastle.com is 217.199.161.3. 1. Query: what is the IP address of www.wraycastle.com. .c raycastle w . w w w ss. add. add. res s. res. ww. so. r e serve. w.w ray c as. fw. ww .wr. om. tle.. wraycastle.com name server. com. ayc as. tle.. com. host local host www.wraycastle.com Figure 29 Name Resolution IP2300/S1/v2.1. © Wray Castle Limited. 1.60.

(74) IP Engineering Overview. 6.6. DNS Implementation. 6.6.1. DNS Data Structure. The commonest use of the DNS is to map from a Fully Qualified Domain Name (FQDN) to the corresponding IP address of the host, or vica versa, as shown in the previous diagram. In fact each entry in the DNS can have a large number of properties associated with it. Each property is stored as a set of four parameters: • the Type field indicates which parameter is stored • the Class field indicates the protocol family • the Time To Live (TTL) field indicates for how long the data may be cashed by a resolver or other cache before a fresh request should be made to the definitive source of the data • the Data field holds the actual parameter value Most records of interest are of class IN, for Internet. The data field might be an IP address, or a FQDN, or other field, depending upon the type of parameter being stored.. 6.6.2. Commonly Used DNS Entries. Figure 30 shows a few of the key parameters commonly accessed in the DNS, together with how these might be used in forwarding an e-mail. In this example, an organization has its own domain name, but uses a commercial hosting service for its e-mail and web presence. • the A fields gives the IPv4 address of a host named • the MX fields gives the FQDN of a Mail eXchange (i.e. a mail forwarder or server) • the CNAME field gives the canonical name matching an alias, in other words the actual definitive name for a host • the TXT field gives freeform text related to the host, for example its type or location Another key entry in the DNS is the Start of Authority (SOA) record. The SOA gives various times and sequence numbers that are important to control for how long any downstream server caches the information it obtains from a zone transfer.. 1.61. © Wray Castle Limited. IP2300/S1/v2.1.

(75) IP Engineering Overview. > dig -t MX wraycastle.com wraycastle.com wraycastle.com. 43049 43049 . . . . 172616 172616. wraycastle.com wraycastle.com. IN MX 10 wray-ltd.demon.co.uk IN MX 20 etrn.magic-moments.com. IN NS IN NS. NS0.magic-moments.com 34155 IN A NS1.magic-moments.com 25665 IN A. Time to Live (TTL) in seconds. Class. A: MX: CNAME: TXT: NS:. NS0.magic-moments.com NS1.magic-moments.com. 217.199.161.27 212.67.202.220. Type. Data. IPv4 address Mail eXchanger Canonical Name Free-form textual information Name server. Figure 30 Data Structures Within the DNS IP2300/S1/v2.1. © Wray Castle Limited. 1.62.

(76) IP Engineering Overview. 6.7. Types of DNS Server. 6.7.1. Primary Name Server. Each domain must have a primary domain server. It is the administrative point for the control and configuration of the domain. This is where hosts are added and zones are maintained.. 6.7.2. Secondary Name Server. Secondary name servers obtain their data from the primary server, which has authority for the zone. This transfer of data is called a zone transfer. Secondary servers give redundancy, faster access at remote locations, can avoid resolving across slow links, and allow load sharing across multiple servers. The primary and secondary server definition is set at zone level, hence a secondary server in one zone may be a primary server in another. Information for each zone is stored in a separate file on the server.. 6.7.3. Caching Servers/Forwarders. Cache servers are often used to conduct queries for resolvers (clients) and cache the results; they have no authority for zone databases. If the cache does not hold the requested DNS information already, it performs a recursive query to obtain it, and then caches the result. Most ISPs operate caching servers, and implemented properly they can substantially speed up the operation of the DNS. Forwarders are normally caches that hold no DNS data, and so must forward all requests they receive.. 1.63. © Wray Castle Limited. IP2300/S1/v2.1.

(77) IP Engineering Overview. Primary name server moves, changes, updates. zone transfer. DNS requests. Secondary name server. Caching name server. DNS requests. Forwarder DNS requests. Resolver. Figure 31 Types of DNS Server IP2300/S1/v2.1. © Wray Castle Limited. 1.64.

(78) IP Engineering Overview. 6.8. Querying the Domain Name System. Details of the primary and one secondary name server are required when a domain is registered, and the names and addresses of the name servers are one of the fields returned by a basic ‘whois’ query against a domain. Other tools that are standard on Unix systems allow interactive querying of the DNS, including the host command, the dig command, and nslookup command. Many web sites provide web-based access to these tools.. 1.65. © Wray Castle Limited. IP2300/S1/v2.1.

(79) IP Engineering Overview. whois wraycastle.com . . Name Server ........................ NS1.MAGIC-MOMENTS.COM Name Server ........................ NS0.MAGIC-MOMENTS.COM host -t ns wraycastle.com. wraycastle.com NS ns1.magic-moments.com wraycastle.com NS ns0.magic-moments.com host -t mx wraycastle.com. wraycastle.com mail is handled (pri=10) by wray-ltd.demon.co.uk wraycastle.com mail is handled (pri=20) by etrn.magic-moments.com dig @<nameserver> wraycastle.com. axfr will return all DNS entries for the host through a zone transfer, if the name server permits it. Figure 32 Tools to Query the DNS IP2300/S1/v2.1. © Wray Castle Limited. 1.66.

(80) IP Engineering Overview. 7. THE APPLICATION LAYER. 7.1. Hypertext Transfer Protocol (HTTP) for Web Services. Hypertext Transfer Protocol (HTTP) is specified in IETF RFC 2616. It is a generic, stateless, object-oriented protocol that can be used for many tasks. HTTP has been in use by the WWW global information initiative since 1990. This first version, known as HTTP/0.9, was a simple protocol for raw data transfer across the Internet. HTTP/1.0 refined the earlier version by the introduction of MIME-like messages. These Multipurpose Internet Mail Extensions (MIME) messages contained meta-information about the data transferred and modifiers on the request/response semantics. The current version, HTTP/1.1 (RFC 2616) provides persistent connections, so that multiple requests and responses can be carried across a single connection, rather than requiring a new connection for each protocol exchange. It also supports a negotiation on compression of data. Both of these changes improve the efficiency and responsiveness of the protocol. HTTP is best described as a request/response protocol. A client, normally a web browser application, sends a request to the server in the form of a request method, URI (Uniform Resource Identifier) and protocol version, followed by a MIME-like message containing request modifiers, client information, and possibly content. The server runs a process or daemon which listens for HTTP requests, and responds to the client with a status line, including the message’s protocol version and a success or error code, followed by a MIME-like message containing server information, entity meta-information, and possibly entity-body content. The status codes returned by the server are grouped into major categories as follows: • Informational. 1xx. • Success. 2xx. • Redirection. 3xx. • Client Error. 4xx. • Server Errors. 5xx. The ISP browser software will provide the User Agent (UA) HTTP communication between itself and the resource located on some (HTTP) Origin Server (OS), the OS being the device containing the requested resource(s). The simplest type of connection is direct between the user and the OS, as shown in Figure 33. Other forms of connection are those of the UA to OS with a number of other network devices in between. These will be proxies, gateways, or tunnelling servers.. 1.67. © Wray Castle Limited. IP2300/S1/v2.1.

(81) IP Engineering Overview. a) User Agent to Origin Server – Direct Connection Origin Server IP resU single connection User Agent HTTP. Resources Database. b) User Agent to Origin Server – via Proxy Server Server acting as proxy. Origin Server. IP resU connection. connection. User Agent HTTP. HTTP. HTTP Transfer. Resources Database. Figure 33 HTTP Connections IP2300/S1/v2.1. © Wray Castle Limited. 1.68.

(82) IP Engineering Overview. 7.2. Simple Mail Transfer Protocol (SMTP) E-mail. Internet mail is based on RFC 821, which defines the Simple Mail Transfer Protocol (SMTP), and RFC 822, which defines the format of Internet Text Messages. A further set of RFCs, RFC 2045-2049 inclusive, defines the MIME, which are extensions to the standard text messages found in RFC 822. These extensions allow the inclusion of multimedia information within the e-mail. SMTP was originally designed for use on Unix machines that were permanently connected to each other. Individual users of these machines have a mailbox to which messages can be delivered, whether they are logged in or not. In the SMTP architecture, mail users interact with a Mail User Agent (MUA), which in turn queues their messages for transport between machines by Message Transfer Agents (MTA). The MUA provides the interface to the user, as well as presenting views of various mailboxes, etc. The MTAs communicate with each other across a TCP connection using SMTP messages. Mail for users is received from an MTA by a Mail Delivery Agent (MDA), which places the mail in the appropriate mailbox. SMTP is a very simple command/response protocol. Five commands are used in this example to send mail between the MTAs. • HELO is used to establish the SMTP connection, • MAIL is used to identify the sender of an outbound e-mail • RCPT is used to identify the recipient of an outbound e-mail • DATA is used to begin sending the message body • QUIT is used to close the SMTP connection There are additional SMTP commands, including RSET, to abort the current connection, and TURN, to allow client and server to swap roles without having to start a new TCP connection.. 1.69. © Wray Castle Limited. IP2300/S1/v2.1.

(83) IP Engineering Overview. SMTP MTA (Client). SMTP MTA (Server) TCP connection to port 25. Mailboxes. e.com 220 mailser ver.acm HELO mailser ver.w raycastle.com. 250 mailser ver.acm. e.com. MAIL FROM: <anoth [email protected]. >. raycastle.com> 250 <another@w RCPT to: <jdoe@ac. 250 <jdoe@acm. me.com>. e.com>. DATA. ge 354 Enter messa (body of message). ed 250 mail accept QUIT. ection 221 closing conn. Figure 34 SMTP Protocol Operation IP2300/S1/v2.1. © Wray Castle Limited. 1.70.

References

Related documents

notably Internet Assigned Numbers Authority (IANA) which ICANN now operates. • Responsible for coordination of IP 4

 Internet Society: Internet Engineering Task Force Internet Architecture Board. Internet Assigned Number Authority World-Wide-Web

The Internet Corporation for Assigned Names and Numbers (ICANN) has responsibility for Internet Protocol (IP) address space allocation (through IANA), and the operation and

Government’s National Telecommunications and Information Administration (NTIA) and the Internet Corporation for Assigned Names and Numbers (ICANN) as defined by the Internet

central global source – the IANA (Internet Assigned Numbers Authority) – the five Regional Internet Registries (RIRs) manage the distribution of IP addresses directly to

• Advises on operation of the domain • Advises on security and integrity of • Advises on ICANN activities as they relate Root Server System Advisory Committee (RSSAC)

ICANN: Internet Corporation for Assigned Names &amp; Numbers. SLD: Second

• The Internet Corporation for Assigned Names and Numbers (ICANN) is an internationally organized, non-profit corporation that has responsibility for Internet Protocol (IP)