Unit 4: The Transport Layer (TCP/UDP)
When we talk about networks, we are talking about data transport. The TCP/IP stack provides a TCP/UDP layer that handles the data transport between machines across networks. In this unit, you will learn the TCP and UDP protocols by examining the structure of TCP and UDP segments and identifying how this layer serves as the application layer in the TCP/IP stack.
Each application relies on the transport layer that is described in this unit. It is a key layer in today's networks, containing all the mechanisms necessary to deliver reliable data over an unreliable network. First, we will develop a simple, reliable transport layer protocol. Then, we will link the details of the TCP and UDP protocols used in TCP/IP networks. We will also study Stream Control Transmission Protocol (SCTP) and Real-Time Transport Protocol (RTP). These protocols are the fundamental protocols for modern multimedia applications over the Internet.
Completing this unit should take you approximately 5 hours.
Upon successful completion of this unit, you will be able to:
- describe the use of the Transmission Control Protocol (TCP) and User Datagram Protocol (UDP) to transfer data segments;
- explain the use of the TCP and UDP header fields;
- explain the transport layer port addressing scheme and port address assignments;
- describe the Stream Control Transmission Protocol (SCTP) and Real-time Transport Protocol (RTP) and the applications based on these protocols;
- explain the mechanics of a TCP connection establishment (3-way handshake) and release;
- illustrate the TCP transmission policy and window management; and
- illustrate congestion control protocols used by TCP, such as Slow Start, Fast Retransmit, and Fast Recovery.
- describe the use of the Transmission Control Protocol (TCP) and User Datagram Protocol (UDP) to transfer data segments;
4.1: The Transport Layer
This section discusses the transport protocol in perfect and imperfect network service environments in terms of interactions with the Service Data Unit (SDU) at various stages of the transmission between sending and receiving nodes. What happens to your transmission when the environment is perfect? If your data gets corrupted by transmission errors, lost, reordered, or duplicated, then what happens? When something goes wrong, what mechanisms are used to repair impacted activity?
4.2: User Datagram Protocol (UDP)
The UDP allows several applications running on a host to exchange SDUs with several other applications running on remote hosts. This section explores the checksum process and how the UDP accomplishes this multiprocessing.
4.3: Transmission Control Protocol (TCP)
Almost every Internet application relies on the TCP in the transport layer. In this section, you will discover how your favorite Internet activity exchanges data worldwide. Then, as you continue through this unit, you will be able to travel with your data as it streams to its destination and back.
As you read this section, make sure you can describe the three-way handshake used by TCP to establish a connection.
As you read this section, make sure you are able to identify and explain the two types of connection release.
This section covers TCP's mechanisms for reliable data transfer, including how sequence and acknowledgment numbers ensure data integrity and how window sizes manage the flow of data to prevent overloading the receiver. How do these elements work together to maintain a stable and ordered data transfer process? How do sequence numbers and acknowledgments enhance the reliability of TCP communication?
Read this section on the Nagle Algorithm. What two strategies does it provide for data transmission?
Read this section on TCP windows. How does a TCP window improve processing in the transport layer?
Follow the path in this section to see how the TCP retransmission timeout improves transport performance.
As you read this section, consider the following questions: What is the exponential back off and how does TCP use it? What is the delayed acknowledgment strategy in TCP? What is the fast retransmit heuristic as utilized by TCP? What is the SACK option?
TCP's congestion control is one of its best performance control features. This section explains this feature and how it improves performance in the transport layer.
Read this tutorial to understand congestion management at different levels: end-to-end, router assisted, and pricing based.
4.4: Stream Control Transmission Protocol (SCTP)
Watch this video up to 8:56 to learn about Stream Control Transmission Protocol (SCTP). SCTP is a versatile transport protocol designed to manage multimedia and stream traffic. It's important to distinguish SCTP from the Transmission Control Protocol (TCP) and the User Datagram Protocol (UDP). Pay particular attention to their respective orientations and levels of reliability. Additionally, familiarize yourself with SCTP's various service types, including process-to-process communication, multiple streams, and multihoming capabilities.
4.5: Real Time Transport Protocol (RTP)
Watch this video up to 14:25 to learn about the vulnerabilities in the Real-Time Transport Protocol (RTP) used for streaming audio and video content over IP networks. Knowledge of RTP's architecture and the significance of using randomized sequence numbers and timestamps to improve security. The video gives a hands-on demonstration of a critical vulnerability within the Asterisk PBX system, where RTP sessions can be hijacked by packets with incorrect source information. This points out the need for packet validation in RTP implementations to prevent unauthorized access and to ensure secure communication.
4.6: Summary
Read this summary of the transport layer, which relies on TCP mechanisms to recover from the errors of the network layer. Review the strategies at each stage of the transmission.
4.7: Practice Exercises
These exercises further expand the key principles in this chapter. As a computer professional, you will enjoy the challenges and higher-level discussions in this section. If you are a novice, explore the presentations and spend more time on the topics that are meaningful to you.
Unit 4 Assessment
- Receive a grade
Take this assessment to see how well you understood this unit.
- This assessment does not count towards your grade. It is just for practice!
- You will see the correct answers when you submit your answers. Use this to help you study for the final exam!
- You can take this assessment as many times as you want, whenever you want.