APPENDIX F THE TCP/IP PROTOCOL ARCHITECTURE

Similar documents
Chapter 3 Protocols and the TCP/IP Suite

Data and Computer Communications

Need For Protocol Architecture

Need For Protocol Architecture

Computer Networks with Internet Technology William Stallings. Chapter 2 Protocols and the TCP/IP Protocol Suite

BLM6196 COMPUTER NETWORKS AND COMMUNICATION PROTOCOLS

Data & Computer Communication

Chapter 2 - Part 1. The TCP/IP Protocol: The Language of the Internet

ECE4110 Internetwork Programming. Introduction and Overview

Data and Computer Communications. Chapter 2 Protocol Architecture, TCP/IP, and Internet-Based Applications

Concept Questions Demonstrate your knowledge of these concepts by answering the following questions in the space that is provided.

Introduction to Open System Interconnection Reference Model

Internetwork Protocols

TCP/IP THE TCP/IP ARCHITECTURE

Introduction to Internetworking

SEN366 (SEN374) (Introduction to) Computer Networks

EE 610 Part 2: Encapsulation and network utilities

Lecture 2. Computer Networks Models. Network Models 1-1

Networking interview questions

ET4254 Communications and Networking 1

Transport Layer. Gursharan Singh Tatla. Upendra Sharma. 1

CHAPTER-2 IP CONCEPTS

Computer Networks. Introduction to Network. Dr. Adel Gaafar Abd Elrahim

TCP/IP protocol suite

CCNA Exploration Network Fundamentals. Chapter 04 OSI Transport Layer

Internet Protocols (chapter 18)

Lecture 17 Overview. Last Lecture. Wide Area Networking (2) This Lecture. Internet Protocol (1) Source: chapters 2.2, 2.3,18.4, 19.1, 9.

TCPIP Protocol Suite & Utilities. Revision no.: PPT/2K403/02

CPS221 Lecture: Layered Network Architecture

ELC 537 Communication Networks

Chapter 5 OSI Network Layer

Introduction to TCP/IP networking

OSI Network Layer. Chapter 5

CCNA 1 Chapter 7 v5.0 Exam Answers 2013

Introduction to Protocols

Defining Networks with the OSI Model. Module 2

ETSF05/ETSF10 Internet Protocols Network Layer Protocols

Goals and topics. Verkkomedian perusteet Fundamentals of Network Media T Circuit switching networks. Topics. Packet-switching networks

Internetworking Terms. Internet Structure. Internet Structure. Chapter 15&16 Internetworking. Internetwork Structure & Terms

Computer Networks (Introduction to TCP/IP Protocols)

Review of Important Networking Concepts

Cisco Cisco Certified Network Associate (CCNA)

IP Address Assignment

Chapter 7. Local Area Network Communications Protocols

User Datagram Protocol

Lesson 5 TCP/IP suite, TCP and UDP Protocols. Chapter-4 L05: "Internet of Things ", Raj Kamal, Publs.: McGraw-Hill Education

Concept Questions Demonstrate your knowledge of these concepts by answering the following questions in the space provided.

Operating Systems. 16. Networking. Paul Krzyzanowski. Rutgers University. Spring /6/ Paul Krzyzanowski

Tutorials and Practicals 31W6 ADMINISTRIVIA. A Communications Model. Communications and Networks. Simplified Communications

Guide To TCP/IP, Second Edition UDP Header Source Port Number (16 bits) IP HEADER Protocol Field = 17 Destination Port Number (16 bit) 15 16

OSI Network Layer. Network Fundamentals Chapter 5. Version Cisco Systems, Inc. All rights reserved. Cisco Public 1

Interconnecting Networks with TCP/IP. 2000, Cisco Systems, Inc. 8-1

CCNA R&S: Introduction to Networks. Chapter 7: The Transport Layer

TCP/IP Transport Layer Protocols, TCP and UDP

03 The Internet Model and TCP/IP

06/02/ Local & Metropolitan Area Networks 0. INTRODUCTION. 1. History and Future of TCP/IP ACOE322

COSC 6377 Mid-Term #2 Fall 2000

NT1210 Introduction to Networking. Unit 10

Transport Layer. The transport layer is responsible for the delivery of a message from one process to another. RSManiaol

b) Diverse forms of physical connection - all sorts of wired connections, wireless connections, fiber optics, etc.

precise rules that govern communication between two parties TCP/IP: the basic Internet protocols IP: Internet protocol (bottom level)

4.0.1 CHAPTER INTRODUCTION

Lecture (11) OSI layer 4 protocols TCP/UDP protocols

CN1047 INTRODUCTION TO COMPUTER NETWORKING CHAPTER 6 OSI MODEL TRANSPORT LAYER

The Internet. 9.1 Introduction. The Internet is a global network that supports a variety of interpersonal and interactive multimedia applications.


OSI Layer OSI Name Units Implementation Description 7 Application Data PCs Network services such as file, print,

OSI Transport Layer. Network Fundamentals Chapter 4. Version Cisco Systems, Inc. All rights reserved. Cisco Public 1

ET4254 Communications and Networking 1

Guide to Networking Essentials, 6 th Edition. Chapter 5: Network Protocols

Prof. Shervin Shirmohammadi SITE, University of Ottawa. Internet Protocol (IP) Lecture 2: Prof. Shervin Shirmohammadi CEG

Connectionless and Connection-Oriented Protocols OSI Layer 4 Common feature: Multiplexing Using. The Transmission Control Protocol (TCP)

TRANSMISSION CONTROL PROTOCOL. ETI 2506 TELECOMMUNICATION SYSTEMS Monday, 7 November 2016

L6: OSI Reference Model

TSIN02 - Internetworking

Network Model: Each layer has a specific function.

CCNA 1 v3.11 Module 11 TCP/IP Transport and Application Layers

PROGRAMMING Kyriacou E. Frederick University Cyprus. Network communication examples

Interconnecting Networks with TCP/IP

System Programming. Introduction to computer networks

1: Review Of Semester Provide an overview of encapsulation.

4. The transport layer

TCP /IP Fundamentals Mr. Cantu

Chapter 2 Network Models 2.1

EEC-484/584 Computer Networks

Chapter 6. The Protocol TCP/IP. Introduction to Protocols

Introduction to Internet. Ass. Prof. J.Y. Tigli University of Nice Sophia Antipolis

Course 6. Internetworking Routing 1/33

Lecture 2 Communication services The Trasport Layer. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it

B.Sc. (Hons.) Computer Science with Network Security B.Eng. (Hons) Telecommunications B.Sc. (Hons) Business Information Systems

Lecture-4. TCP/IP-Overview:

UDP and TCP. Introduction. So far we have studied some data link layer protocols such as PPP which are responsible for getting data

CompSci 356: Computer Network Architectures. Lecture 8: Spanning Tree Algorithm and Basic Internetworking Ch & 3.2. Xiaowei Yang

SE 4C03 Winter Final Examination Answer Key. Instructor: William M. Farmer

CHAPTER 18 INTERNET PROTOCOLS ANSWERS TO QUESTIONS

Data and Computer Communications. Protocols and Architecture

The TCP Protocol Stack

PART X. Internetworking Part 1. (Concept, IP Addressing, IP Routing, IP Datagrams, Address Resolution)

Position of IP and other network-layer protocols in TCP/IP protocol suite

Internet Protocol version 6

Transcription:

APPENDIX F THE TCP/IP PROTOCOL ARCHITECTURE William Stallings F.1 TCP/IP LAYERS... 2 F.2 TCP AND UDP... 4 F.3 OPERATION OF TCP/IP... 6 F.4 TCP/IP APPLICATIONS... 10 Copyright 2014 Supplement to Computer Security, Third Edition Pearson 2014 http://williamstallings.com/computersecurity

TCP/IP is a result of protocol research and development conducted on the experimental packet-switched network, ARPANET, funded by the Defense Advanced Research Projects Agency (DARPA), and is generally referred to as the TCP/IP protocol suite. This protocol suite consists of a large collection of protocols that have been issued as Internet standards by the Internet Activities Board (IAB). Appendix A provides a discussion of Internet standards. F.1 TCP/IP LAYERS In general terms, communications can be said to involve three agents: applications, computers, and networks. Examples of applications include file transfer and electronic mail. The applications that we are concerned with here are distributed applications that involve the exchange of data between two computer systems. These applications, and others, execute on computers that can often support multiple simultaneous applications. Computers are connected to networks, and the data to be exchanged are transferred by the network from one computer to another. Thus, the transfer of data from one application to another involves first getting the data to the computer in which the application resides and then getting the data to the intended application within the computer. There is no official TCP/IP protocol model. However, based on the protocol standards that have been developed, we can organize the communication task for TCP/IP into five relatively independent layers, from bottom to top: Physical layer Network access layer Internet layer F-2

Host-to-host, or transport layer Application layer The physical layer covers the physical interface between a data transmission device (e.g., workstation, computer) and a transmission medium or network. This layer is concerned with specifying the characteristics of the transmission medium, the nature of the signals, the data rate, and related matters. The network access layer is concerned with the exchange of data between an end system (server, workstation, etc.) and the network to which it is attached. The sending computer must provide the network with the address of the destination computer, so that the network may route the data to the appropriate destination. The sending computer may wish to invoke certain services, such as priority, that might be provided by the network. The specific software used at this layer depends on the type of network to be used; different standards have been developed for circuit switching, packet switching (e.g., frame relay), LANs (e.g., Ethernet), and others. Thus it makes sense to separate those functions having to do with network access into a separate layer. By doing this, the remainder of the communications software, above the network access layer, need not be concerned about the specifics of the network to be used. The same higher-layer software should function properly regardless of the particular network to which the computer is attached. The network access layer is concerned with access to and routing data across a network for two end systems attached to the same network. In those cases where two devices are attached to different networks, procedures are needed to allow data to traverse multiple interconnected networks. This is the function of the internet layer. The Internet Protocol (IP) is used at this layer to provide the routing function across multiple F-3

networks. This protocol is implemented not only in the end systems but also in routers. A router is a processor that connects two networks and whose primary function is to relay data from one network to the other on a route from the source to the destination end system. Regardless of the nature of the applications that are exchanging data, there is usually a requirement that data be exchanged reliably. That is, we would like to be assured that all the data arrive at the destination application and that the data arrive in the same order in which they were sent. As we shall see, the mechanisms for providing reliability are essentially independent of the nature of the applications. Thus, it makes sense to collect those mechanisms in a common layer shared by all applications; this is referred to as the host-to-host layer, or transport layer. The Transmission Control Protocol (TCP) is the most commonly used protocol to provide this functionality. Finally, the application layer contains the logic needed to support the various user applications. For each different type of application, such as file transfer, a separate module is needed that is peculiar to that application. F.2 TCP AND UDP For most applications running as part of the TCP/IP protocol architecture, the transport layer protocol is TCP. TCP provides a reliable connection for the transfer of data between applications. A connection is simply a temporary logical association between two entities in different systems. For the duration of the connection each entity keeps track of segments coming and going to the other entity, in order to regulate the flow of segments and to recover from lost or damaged segments. F-4

Bit: 0 4 8 16 31 Source Port Destination Port 20 octets Header length Sequence Number Acknowledgement Number Reserved Flags Window Checksum Urgent Pointer Options + Padding 8 octets Bit: 0 16 Source Port Segment Length (a) TCP Header Destination Port Checksum 31 (b) UDP Header Figure F.1 TCP and UDP Headers Figure F.1a shows the header format for TCP, which is a minimum of 20 octets, or 160 bits. The Source Port and Destination Port fields identify the applications at the source and destination systems that are using this connection. The Sequence Number, Acknowledgment Number, and Window fields provide flow control and error control. The checksum is a 16-bit code based on the contents of the segment used to detect errors in the TCP segment. F-5

In addition to TCP, there is one other transport-level protocol that is in common use as part of the TCP/IP protocol suite: the User Datagram Protocol (UDP). UDP does not guarantee delivery, preservation of sequence, or protection against duplication. UDP enables a process to send messages to other processes with a minimum of protocol mechanism. Some transaction-oriented applications make use of UDP; one example is SNMP (Simple Network Management Protocol), the standard network management protocol for TCP/IP networks. Because it is connectionless, UDP has very little to do. Essentially, it adds a port addressing capability to IP. This is best seen by examining the UDP header, shown in Figure F.1b. F.3 OPERATION OF TCP/IP Figure F.2 indicates how these protocols are configured for communications. Some sort of network access protocol, such as the Ethernet logic, is used to connect a computer to a network. This protocol enables the host to send data across the network to another host or, in the case of a host on another network, to a router. IP is implemented in all end systems and routers. It acts as a relay to move a block of data from one host, through one or more routers, to another host. TCP is implemented only in the end systems; it keeps track of the blocks of data being transferred to assure that all are delivered reliably to the appropriate application. F-6

Host A Host B App Y App X Port App X App Y 1 2 3 Logical connection 2 4 6 (TCP connection) TCP TCP IP Global internet address IP Network Access Protocol #1 Physical Subnetwork attachment point address Router J Logical connection (e.g., virtual circuit) Network Access Protocol #2 Physical IP NAP 1 NAP 2 Network 1 Network 2 Physical Physical Figure F.2 TCP/IP Concepts For successful communication, every entity in the overall system must have a unique address. In fact, two levels of addressing are needed. Each host on a network must have a unique global internet address; this allows the data to be delivered to the proper host. This address is used by IP for routing and delivery. Each application within a host must have an address that is unique within the host; this allows the host-to-host protocol (TCP) to deliver data to the proper process. These latter addresses are known as ports. Let us trace a simple operation. Suppose that a process, associated with port 3 at host A, wishes to send a message to another process, associated F-7

with port 2 at host B. The process at A hands the message down to TCP with instructions to send it to host B, port 2. TCP hands the message down to IP with instructions to send it to host B. Note that IP need not be told the identity of the destination port. All it needs to know is that the data are intended for host B. Next, IP hands the message down to the network access layer (e.g., Ethernet logic) with instructions to send it to router J (the first hop on the way to B). To control this operation, control information as well as user data must be transmitted, as suggested in Figure F.3. Let us say that the sending process generates a block of data and passes this to TCP. TCP may break this block into smaller pieces to make it more manageable. To each of these pieces, TCP appends control information known as the TCP header (Figure F.1a), forming a TCP segment. The control information is to be used by the peer TCP protocol entity at host B. Examples of items in this header include Destination port: When the TCP entity at B receives the segment, it must know to whom the data are to be delivered. Sequence number: TCP numbers the segments that it sends to a particular destination port sequentially, so that if they arrive out of order, the TCP entity at B can reorder them. Checksum: The sending TCP includes a code that is a function of the contents of the remainder of the segment. The receiving TCP performs the same calculation and compares the result with the incoming code. A discrepancy results if there has been some error in transmission. F-8

User data Application byte stream TCP header TCP segment IP header IP datagram Network header Network-level packet Figure F.3 Protocol Data Units (PDUs) in the TCP/IP Architecture Next, TCP hands each segment over to IP, with instructions to transmit it to B. These segments must be transmitted across one or more networks and relayed through one or more intermediate routers. This operation, too, requires the use of control information. Thus IP appends a header of control information (Figure F.3) to each segment to form an IP datagram. An example of an item stored in the IP header is the destination host address (in this example, B). Finally, each IP datagram is presented to the network access layer for transmission across the first network in its journey to the destination. The network access layer appends its own header, creating a packet, or frame. F-9

The packet is transmitted across the network to router J. The packet header contains the information that the network needs in order to transfer the data across the network. Examples of items that may be contained in this header include: Destination network address: The network must know to which attached device the packet is to be delivered, in this case router J. Facilities requests: The network access protocol might request the use of certain network facilities, such as priority. At router J, the packet header is stripped off and the IP header examined. On the basis of the destination address information in the IP header, the IP module in the router directs the datagram out across network 2 to B. To do this, the datagram is again augmented with a network access header. When the data are received at B, the reverse process occurs. At each layer, the corresponding header is removed, and the remainder is passed on to the next higher layer, until the original user data are delivered to the destination process. F.4 TCP/IP APPLICATIONS A number of applications have been standardized to operate on top of TCP. We mention three of the most common here. The Simple Mail Transfer Protocol (SMTP) provides a basic electronic mail facility. It provides a mechanism for transferring messages among separate hosts. Features of SMTP include mailing lists, return receipts, and forwarding. The SMTP protocol does not specify the way in which messages are to be created; some local editing or native electronic mail facility is F-10

required. Once a message is created, SMTP accepts the message and makes use of TCP to send it to an SMTP module on another host. The target SMTP module will make use of a local electronic mail package to store the incoming message in a user's mailbox. The File Transfer Protocol (FTP) is used to send files from one system to another under user command. Both text and binary files are accommodated, and the protocol provides features for controlling user access. When a user wishes to engage in file transfer, FTP sets up a TCP connection to the target system for the exchange of control messages. This connection allows user ID and password to be transmitted and allows the user to specify the file and file actions desired. Once a file transfer is approved, a second TCP connection is set up for the data transfer. The file is transferred over the data connection, without the overhead of any headers or control information at the application level. When the transfer is complete, the control connection is used to signal the completion and to accept new file transfer commands. SSH (Secure Shell) provides a secure remote logon capability, which enables a user at a terminal or personal computer to logon to a remote computer and function as if directly connected to that computer. SSH also supports file transfer between the local host and a remote server. SSH enables the user and the remote server to authenticate each other; it also encrypts all traffic in both directions. SSH traffic is carried on a TCP connection. F-11