Tutorial

Routing First-Step: TCP/IP layered protocol model

The following is the fifth installment of a multi-part series on the fundamentals of routing. Each tip is excerpted from Routing First-Step by William Parkhurst, published by Cisco Press. Check back frequently for the next installment,

    Requires Free Membership to View

or go to the main series page for all the installments.

About the book


Routing First-Step explains the basics of Internet routing in language all of us can understand. This book takes you on a guided tour of routing, starting with systems you are familiar with: the postal system, the telephone system, and the interstate highway system. From there, you'll learn routing simply and easily. Whether you are looking to take your first step into a career in networking or are interested only in gaining knowledge of the technology, this book is for you!

Author William R. Parkhurst, Ph.D., CCIE, manages the CCIE Development group at Cisco Systems. The CCIE Development group is responsible for all new CCIE written qualification and laboratory exams. Prior to joining the CCIE team, Bill was a Consulting Systems Engineer supporting the Sprint Operation. He first became associated with Cisco Systems while a Professor of Electrical and Computer Engineering at Wichita State University. In conjunction with Cisco Systems, WSU established the first CCIE Preparation Laboratory.


TCP/IP layered protocol model

There are different types of service that you can use when delivering a letter. You can use a best effort model. This means that you simply place a stamp on the letter and drop it in a mailbox. How do you know if the letter was delivered? You don't. Not unless the recipient somehow tells you they received the letter. If you want to ensure delivery, you could send a registered letter. After the letter has been delivered, you will receive an acknowledgment from the post office. The layered postal delivery model needs to be modified to include this feature. (See Figure 3-14.) Although IP is used to deliver packets, and TCP and UDP are transport level protocols, the layer model for the Internet is usually referred to as the TCP/IP model.

Figure 3-14 - Post Office Layered Protocol Model

At the Addressing – Person layer, two options have been added:

  • Normal delivery - The sender will not receive any acknowledgment that the letter has been delivered.

  • Registered mail - The sender will receive an acknowledgment after the letter has been delivered.

    The Internet layered model has two additional protocols that are equivalent to normal and registered mail:

  • Transmission Control Protocol (TCP) - The equivalent of a registered letter. When data is received at the destination host, an acknowledgment is sent back to the sender.

  • User Datagram Protocol (UDP) - The equivalent of normal mail. An acknowledgment is not sent back to the sender.

    Integrating TCP and UDP into the Internet model gives you the complete TCP/IP layered protocol model. (See Figure 3-15.)

    Figure 3-15 - TCP/IP Layered Model or Protocol Stack

    The port information in the UDP header is used to identify the sending and receiving applications. (See Figure 3-16.)

    Figure 3-16 - UDP Header Format

    The source port is equivalent to the person who is sending the letter. The destination port is equivalent to the person who is to receive the letter. Applications initially will use a well-known port number. For example, if you are using a web browser to contact the Cisco website, your application will send a message to port 80 at IP address 198.133.219.25. The source port is usually assigned dynamically for the application and is included in the UDP header. When the webserver for Cisco.com sends a reply, it will send it back to the dynamic port number that was assigned for the sender's application. The destination IP address is used to reach the host running the web server, and the destination port number is used to reach the proper application. The combination of a port number and an IP address is called a socket. A socket is sufficient to identify a particular application on a specific host.

    The TCP header is similar to the UDP header with additional fields to enable acknowledgments. (See Figure 3-17.)

    Figure 3-17 - TCP Header Format

    The source and destination port numbers serve the same function as they did in the UDP header. The remaining fields are used to send the equivalent of registered mail. The operation of the TCP protocol can be complex. If you are interested in learning more, consult the reference list at the end of the chapter.

    Before moving on to the next exciting topic, let's trace the flow through the TCP/IP protocol stack. (See Figure 3-18.)

    Figure 3-18 - Data Flow Through the TCP/IP Protocol Stack

    The application sends the data, such as the text of an e-mail, you are sending to UDP or TCP where the destination and source port numbers are recorded. The IP layer adds the source and destination IP addresses, and sets the protocol field to UDP or TCP depending on what is being used. The IP layer then hands the packet off to the network interface layer. This example uses Ethernet, so the network interface layer adds the source and destination Ethernet addresses. Finally, the entire thing is sent to the network to be sent to the destination.

    Upon receipt of an IP packet by a host, the destination Ethernet address is first inspected. If it matches the host's Ethernet address, the Ethernet header is stripped off, and the remaining part of the packet is sent up the protocol stack to the IP layer. The IP layer looks at the destination IP address. If it is the correct IP address, the IP layer strips off the IP header, and sends what is left either to TCP or UDP—depending on the setting of the protocol field. UDP or TCP then uses the destination port number to send the data to the correct application.

    All parts reproduced from the book Routing First-Step, ISBN 1587201224, Copyright 2005, Cisco Systems, Inc. Reproduced by permission of Pearson Education, Inc., 800 East 96th Street, Indianapolis, IN 46240. Written permission from Pearson Education, Inc. is required for all other uses. Visit www.ciscopress.com for a detailed description and to learn how to purchase this title.

    This was first published in October 2004

  • There are Comments. Add yours.

     
    TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

    REGISTER or login:

    Forgot Password?
    By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
    Sort by: OldestNewest

    Forgot Password?

    No problem! Submit your e-mail address below. We'll send you an email containing your password.

    Your password has been sent to: