Transport Layer Flashcards

1
Q

What is the primary role of the Transport Layer?

A

To establish a conversation between two applications running on two network devices.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How does the Transport Layer support concurrent applications?

A

By using port numbers to uniquely identify separate flows of data.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are the basic characteristics of TCP?

A

TCP is reliable, connection-oriented, and ensures ordered data transmission with acknowledgments.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are the basic characteristics of UDP?

A

UDP is connectionless, does not guarantee ordered delivery, and does not provide reliability or flow control.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What applications typically use UDP?

A

Real-time applications like DNS, video streaming, and VoIP.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How does the Transport Layer ensure data integrity?

A

By using checksums in the header to verify data integrity.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is the difference between well-known ports and registered ports?

A

Well-known ports are standardized for specific services (0-1023), while registered ports (1024-49151) are assigned for specific applications by IANA.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is the range for dynamic or private ports?

A

49152-65535

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What does the UDP header contain?

A

Source port, destination port, length, and checksum.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is a datagram in the context of UDP?

A

A unit of data transmission, which can be sent without establishing a connection.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Why might UDP be chosen over TCP for certain applications?

A

UDP has lower overhead and allows for faster data transmission, suitable for real-time applications.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is the purpose of port numbers in the Transport Layer?

A

To identify source and destination applications and support concurrent data flows.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

How does TCP provide reliability?

A

By using acknowledgments, sequence numbers, and retransmission of lost packets.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What does it mean for UDP to be a stateless protocol?

A

Neither the client nor the server keeps track of the conversation state or connectivity status.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What type of applications prioritize fast transmission over reliability?

A

Real-time applications like VoIP and video streaming.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is the significance of the UDP checksum?

A

It is used for error-checking the header and data.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What does it mean when UDP is described as providing ‘best-effort’ delivery?

A

There is no guarantee that the data will be delivered or that it will be delivered in order.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

How do transport layer protocols impact application performance?

A

They determine how applications handle data transmission under varying network conditions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

What is the primary purpose of segmenting and reassembling data in the Transport Layer?

A

To prepare data for transmission across the network and reassemble it at the destination.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

How are port numbers used to differentiate multiple conversations between the same hosts?

A

By assigning unique source and destination port numbers for each conversation.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

Why is there no need for flow control in UDP?

A

Because UDP sends data at the source’s capacity without considering the destination’s processing capability.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

What mechanism does TCP use to ensure data is received in order?

A

Sequence numbers in the TCP header.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

Which layer of the OSI model does the Transport Layer correspond to?

A

Layer 4

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

What is the role of the checksum in the UDP header?

A

To detect errors in the transmitted segment.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

What is the maximum number of port numbers available in the Transport Layer?

A

65,535

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
26
Q

What are some examples of well-known TCP ports?

A

80 for HTTP, 443 for HTTPS, 21 for FTP, 25 for SMTP.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
27
Q

What are some examples of well-known UDP ports?

A

53 for DNS, 69 for TFTP, 161 for SNMP.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
28
Q

What is the primary difference between TCP and UDP in terms of reliability?

A

TCP is reliable and ensures delivery of packets, while UDP is not reliable and does not guarantee delivery.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
29
Q

What does a TCP header include that a UDP header does not?

A

Sequence number, acknowledgment number, flags for controlling the state of the connection.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
30
Q

What is a three-way handshake in TCP?

A

A process to establish a TCP connection involving SYN, SYN-ACK, and ACK packets.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
31
Q

How does the Transport Layer handle data segmentation?

A

It breaks down data streams into smaller segments that can be transmitted over the network.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
32
Q

What happens if a segment is lost during transmission in TCP?

A

TCP will retransmit the lost segment based on the acknowledgment and sequence numbers.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
33
Q

Why is UDP considered faster than TCP?

A

Because it has less overhead and does not perform error checking or retransmission.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
34
Q

What is flow control in TCP?

A

A mechanism to control the rate of data transmission between sender and receiver to prevent congestion.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
35
Q

What are some common applications that use TCP?

A

Web browsing (HTTP/HTTPS), email (SMTP), file transfer (FTP).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
36
Q

How does UDP handle datagram reassembly?

A

UDP does not guarantee datagram reassembly in order, and it must be handled by the application layer.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
37
Q

What is the significance of the source port in the Transport Layer?

A

It identifies the sending application on the source host.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
38
Q

What is the significance of the destination port in the Transport Layer?

A

It identifies the receiving application on the destination host.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
39
Q

How does the Transport Layer interact with the Network Layer?

A

The Transport Layer uses IP addresses from the Network Layer to route segments to the correct destination.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
40
Q

What is an ephemeral port?

A

A temporary, short-lived port number assigned by the client’s operating system for communication.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
41
Q

What does ‘connection-oriented’ mean in the context of TCP?

A

It means that a connection is established and maintained until all data is transmitted and acknowledged.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
42
Q

What does ‘connectionless’ mean in the context of UDP?

A

It means that each datagram is sent independently without establishing a connection.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
43
Q

How does TCP ensure data integrity?

A

Through checksums, sequence numbers, and acknowledgments.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
44
Q

Why might a developer choose to use UDP over TCP?

A

For applications where speed is critical and some data loss is acceptable, such as live video streaming.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
45
Q

How does the Transport Layer support error detection and correction?

A

TCP uses mechanisms like checksums and retransmissions; UDP provides minimal error detection with checksums.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
46
Q

What is a socket in networking?

A

An endpoint for sending or receiving data across a network, consisting of an IP address and port number.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
47
Q

What is a tuple in the context of the Transport Layer?

A

A pair of source and destination IP addresses and port numbers that uniquely identify a communication session.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
48
Q

What is the function of the TCP window size?

A

It controls the flow of data and helps manage congestion by specifying the amount of data that can be sent before receiving an acknowledgment.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
49
Q

What is meant by ‘out-of-order’ packets in UDP?

A

Packets that arrive at the destination in a different order than they were sent, due to the lack of sequence numbers in UDP.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
50
Q

How does TCP handle congestion control?

A

Through algorithms like slow start, congestion avoidance, fast retransmit, and fast recovery.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
51
Q

What are some challenges associated with using UDP?

A

No guarantee of delivery, no order of delivery, no congestion control, and error handling must be managed by the application.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
52
Q

What does the TCP flag ‘SYN’ indicate?

A

It indicates a request to establish a new connection.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
53
Q

What does the TCP flag ‘ACK’ indicate?

A

It acknowledges the receipt of a packet.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
54
Q

What does the TCP flag ‘FIN’ indicate?

A

It indicates a request to terminate an existing connection.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
55
Q

What is a TCP segment?

A

A unit of data transmission in TCP, consisting of a header and data payload.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
56
Q

What is a UDP datagram?

A

A self-contained, independent packet of data sent via UDP.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
57
Q

What is the primary use case for TCP?

A

Applications that require reliable communication, such as web browsing, email, and file transfers.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
58
Q

What is the primary use case for UDP?

A

Applications that require fast, real-time communication, such as video streaming and online gaming.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
59
Q

How does TCP handle lost packets?

A

By retransmitting lost packets after detecting missing acknowledgments.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
60
Q

How does UDP handle lost packets?

A

UDP does not handle lost packets; it is up to the application layer to manage any required retransmissions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
61
Q

What is the difference between a socket and a port?

A

A socket is an endpoint for communication, defined by an IP address and port number; a port is a numerical identifier for a specific process or service.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
62
Q

What is multiplexing in the context of the Transport Layer?

A

The ability to handle multiple communication sessions simultaneously by differentiating them with unique port numbers.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
63
Q

What is demultiplexing in the context of the Transport Layer?

A

The process of delivering received data to the correct application process based on the destination port number.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
64
Q

How does TCP provide flow control?

A

By using the window size to regulate the amount of data sent before requiring an acknowledgment.

65
Q

What is the function of the TCP three-way handshake?

A

To establish a reliable connection between a client and server before data transmission begins.

66
Q

What is a port number?

A

A numerical identifier in the Transport Layer used to identify specific processes or services on a host.

67
Q

How does UDP achieve low latency?

A

By minimizing overhead and not performing connection establishment or reliability checks.

68
Q

What is an acknowledgment number in TCP?

A

A number used to confirm the receipt of data segments and indicate the next expected byte.

69
Q

Why is UDP preferred for live broadcasts?

A

Because it offers low latency and does not require retransmissions, which can introduce delays.

70
Q

How does TCP ensure data is delivered in the correct order?

A

By using sequence numbers to track the order of segments.

71
Q

What is a sliding window in TCP?

A

A mechanism for controlling the flow of data and ensuring efficient data transmission without overwhelming the receiver.

72
Q

What are some examples of applications that require TCP’s reliability?

A

Email, file transfer, and web browsing.

73
Q

What is the main disadvantage of using UDP?

A

Lack of reliability and no guarantee of data delivery or order.

74
Q

Why is TCP considered heavier than UDP?

A

Because it includes additional overhead for connection management, error checking, and data recovery.

75
Q

What are some common uses for dynamic or ephemeral ports?

A

Client-side communications, such as web browsing or email retrieval.

76
Q

How does the Transport Layer handle error detection in UDP?

A

By using a simple checksum in the header for error checking.

77
Q

Why is the UDP header smaller than the TCP header?

A

Because UDP does not include fields for connection management or reliability, reducing its overhead.

78
Q

How does TCP handle duplicate packets?

A

By using sequence numbers to identify and discard duplicates.

79
Q

What is the maximum size of a UDP datagram?

A

65,535 bytes, including the header.

80
Q

How does the Transport Layer interact with the Application Layer?

A

It provides end-to-end communication services for applications by handling data segmentation, delivery, and reassembly.

81
Q

What is the role of the Transport Layer in the OSI model?

A

To provide reliable or best-effort delivery of data between end devices over a network.

82
Q

How do transport protocols affect overall network performance?

A

They influence factors like latency, throughput, reliability, and congestion control.

83
Q

What is the function of a checksum in networking?

A

To verify the integrity of data by detecting errors in transmitted packets.

84
Q

Why is port number standardization important in networking?

A

To ensure consistent identification of services and applications across different devices and networks.

85
Q

What is the purpose of a sequence number in TCP?

A

To keep track of the order of segments and ensure correct data reassembly.

86
Q

What is a FIN-WAIT state in TCP?

A

A state indicating that a TCP connection termination process has begun but is not yet complete.

87
Q

What does the term ‘best-effort’ mean in the context of UDP?

A

It means that UDP does not guarantee delivery, order, or error recovery of transmitted data.

88
Q

How does the Transport Layer enhance communication reliability?

A

By providing mechanisms for error detection, retransmission, and flow control (in TCP).

89
Q

What is the relationship between the Transport Layer and the Internet Layer in the OSI model?

A

The Transport Layer uses the Internet Layer to route packets to their destination and provides end-to-end communication services.

90
Q

How do applications choose between TCP and UDP?

A

Based on the application’s requirements for speed, reliability, and data integrity.

91
Q

What is the function of the TCP urgent pointer?

A

To indicate that certain data within a segment is urgent and should be processed immediately.

92
Q

How does the Transport Layer handle data segmentation and reassembly?

A

It breaks data into smaller segments for transmission and reassembles them at the destination.

93
Q

What is the primary function of the Transport Layer in networking?

A

To provide end-to-end communication services for applications, including data segmentation, delivery, and reassembly.

94
Q

What is TCP?

A

Transmission Control Protocol, a reliable layer 4 protocol used in TCP/IP networks.

95
Q

What does TCP stand for?

A

Transmission Control Protocol.

96
Q

Which RFC defines TCP?

A

RFC 793.

97
Q

What type of protocol is TCP?

A

Connection-oriented.

98
Q

What is the primary role of TCP?

A

To provide reliable, ordered, and error-checked delivery of data between applications.

99
Q

What is the three-way handshake in TCP?

A

A process to establish a TCP connection involving SYN, SYN-ACK, and ACK packets.

100
Q

What is the purpose of the TCP three-way handshake?

A

To establish that the destination device is available and has an active service on the destination port number.

101
Q

What does the TCP header contain?

A

Source port, destination port, sequence number, acknowledgment number, data offset, control bits, window size, checksum, urgent pointer.

102
Q

What is a sequence number in TCP?

A

A number used to identify the order of bytes sent in a data stream.

103
Q

What is an acknowledgment number in TCP?

A

A number used to confirm the receipt of data and indicate the next expected byte.

104
Q

What is flow control in TCP?

A

Mechanisms to control the rate of data transmission between sender and receiver to prevent congestion.

105
Q

What is a TCP segment?

A

A unit of data transmission in TCP, consisting of a header and data payload.

106
Q

What is the purpose of the TCP window size?

A

To control the flow of data and ensure efficient data transmission without overwhelming the receiver.

107
Q

What is the sliding window in TCP?

A

A flow control mechanism that allows a sender to send multiple packets before needing an acknowledgment.

108
Q

What is the initial sequence number in TCP?

A

A random number chosen during the three-way handshake to start the sequence numbering for a connection.

109
Q

Why are initial sequence numbers in TCP not zero?

A

For security reasons to prevent certain types of attacks.

110
Q

What happens during TCP connection termination?

A

A four-step process involving FIN and ACK packets from both ends.

111
Q

What is the purpose of the FIN flag in TCP?

A

To indicate the desire to terminate a TCP connection.

112
Q

What is TCP congestion control?

A

Mechanisms to prevent network congestion by adjusting the rate of data transmission.

113
Q

What is the slow start algorithm in TCP?

A

An algorithm to gradually increase the congestion window size to avoid congestion.

114
Q

What is the congestion avoidance algorithm in TCP?

A

An algorithm to increment the congestion window size linearly after reaching a threshold to avoid rapid congestion.

115
Q

What is a congestion window in TCP?

A

A TCP parameter that limits the amount of data that can be sent before receiving an acknowledgment.

116
Q

What happens when a TCP segment is lost?

A

The sender retransmits the segment after detecting the loss through duplicate acknowledgments or timeouts.

117
Q

What is a positive acknowledgment in TCP?

A

An acknowledgment that indicates the next expected byte in the data stream.

118
Q

What is the purpose of the TCP checksum?

A

To verify the integrity of the transmitted segment.

119
Q

What is the maximum segment size (MSS) in TCP?

A

The largest amount of data, in bytes, that TCP is willing to receive in a single segment.

120
Q

What does the PSH flag in TCP indicate?

A

Push Function; it tells the receiver to pass the data to the application as soon as possible.

121
Q

What does the URG flag in TCP indicate?

A

Urgent Pointer field significant; it indicates that the segment contains urgent data.

122
Q

What does the RST flag in TCP indicate?

A

Reset the connection; it is used to abort the connection.

123
Q

What does the ACK flag in TCP indicate?

A

Acknowledgment field significant; it is used to acknowledge the receipt of data.

124
Q

What does the SYN flag in TCP indicate?

A

Synchronize sequence numbers; it is used to initiate a connection.

125
Q

What is the TCP urgent pointer used for?

A

To indicate that certain data within a segment is urgent and should be processed immediately.

126
Q

How does TCP handle duplicate packets?

A

By using sequence numbers to identify and discard duplicates.

127
Q

What is the role of the TCP receiver window?

A

To inform the sender of the maximum amount of data that can be received and processed.

128
Q

What is the role of the TCP congestion window?

A

To manage the rate of data transmission to avoid network congestion.

129
Q

What is the purpose of the acknowledgment timeout in TCP?

A

To retransmit segments if an acknowledgment is not received within a certain period.

130
Q

What is exponential backoff in TCP?

A

A mechanism to reduce the transmission rate exponentially when congestion is detected.

131
Q

What is the impact of UDP traffic on TCP traffic?

A

High UDP traffic can cause TCP to reduce its transmission rate due to increased congestion.

132
Q

What is TCP fairness?

A

The concept that TCP flows share available network bandwidth evenly.

133
Q

What is the role of the TCP data offset field?

A

To specify the size of the TCP header.

134
Q

What is the maximum value of the TCP window size?

A

65,535 bytes.

135
Q

What is a TCP segment loss detection method?

A

Duplicate acknowledgments or timeout mechanisms.

136
Q

What is the purpose of the TCP retransmission timeout (RTO)?

A

To determine when to retransmit a segment if an acknowledgment is not received.

137
Q

What is TCP’s fast retransmit?

A

A mechanism to retransmit a segment before the RTO expires when three duplicate acknowledgments are received.

138
Q

What is the purpose of the TCP congestion window size management?

A

To adjust the transmission rate based on network conditions to prevent congestion.

139
Q

How does TCP handle network congestion?

A

By using algorithms like slow start, congestion avoidance, and fast retransmit to adjust the congestion window size.

140
Q

What is TCP’s flow control challenge with high-bandwidth or long-delay links?

A

Balancing the window size to maximize throughput without causing congestion.

141
Q

What is the effect of a small TCP window size?

A

Underutilization of network bandwidth.

142
Q

What is the effect of a large TCP window size?

A

Increased risk of network congestion and packet loss.

143
Q

How does TCP achieve reliable data transfer?

A

Through sequence numbers, acknowledgments, retransmissions, and flow control mechanisms.

144
Q

What is the purpose of the TCP window size adjustment?

A

To optimize data transmission and avoid network congestion.

145
Q

What is the impact of TCP’s sliding window mechanism on data transmission?

A

It allows for efficient and continuous data transmission by sending multiple segments before waiting for acknowledgments.

146
Q

What are TCP’s congestion control algorithms?

A

Slow start, congestion avoidance, fast retransmit, and fast recovery.

147
Q

What is the function of the TCP three-way handshake?

A

To establish a reliable connection between a client and server before data transmission begins.

148
Q

How does TCP ensure in-order delivery of segments?

A

By using sequence numbers to reassemble segments in the correct order at the receiver.

149
Q

How does TCP handle flow control and congestion management?

A

Through window size adjustments and congestion control algorithms to manage data transmission rates.

150
Q

What is the significance of the TCP acknowledgment number?

A

It indicates the next expected byte, confirming receipt of data and managing flow control.

151
Q

What is the TCP fast recovery algorithm?

A

An algorithm to quickly recover from packet loss by temporarily reducing the congestion window size.

152
Q

What is the TCP maximum segment size (MSS)?

A

The largest segment of data that TCP is willing to receive, excluding headers.

153
Q

Why is the TCP initial sequence number randomly chosen?

A

For security reasons to prevent certain types of attacks and predictability.

154
Q

How does TCP handle out-of-order segments?

A

By storing them temporarily and using sequence numbers to reassemble them in the correct order.

155
Q

Why is TCP considered reliable?

A

Because it ensures data delivery through acknowledgments, retransmissions, and error-checking mechanisms.

156
Q

What is the purpose of the TCP urgent pointer?

A

To indicate urgent data that should be processed immediately.

157
Q

How does TCP’s congestion avoidance algorithm work?

A

By incrementing the congestion window size linearly after reaching a threshold to prevent rapid congestion.

158
Q

How does TCP slow start algorithm operate?

A

By initially setting a small congestion window and exponentially increasing it until congestion is detected.

159
Q

What is TCP’s role in network congestion management?

A

To adjust data transmission rates based on network conditions, preventing congestion and ensuring fair bandwidth distribution.