Transport Layer Flashcards

1
Q

Transport Layer:

A

Provides logical communication between application processes running on different hosts

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

Multiplexing:

A

Handles data from multiple sockets, and add them to the transport layer

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

Connectionless multiplexing/demultiplexing:

A

Involves handling multiple data streams from different applications without establishing a dedicated, continuous connection between the endpoints

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

Transmission in UDP:

A

When data is sent, each piece of data is treated independently of others. Datagrams are sent directly to the destination without establishing a connection. Each datagram contains enough information in its header (such as source and destination port numbers) to be routed and delivered to the correct application.

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

Demultiplexing:

A

At the receiving side, the transport layer examines the destination port number in each UDP datagram’s header. It uses this port number to deliver the datagram to the correct application.

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

Port Numbers:

A

UDP uses port numbers to direct traffic to the correct receiving application. Each application binds to a specific port number, and the transport layer uses this number to identify where the incoming and outgoing data should go.

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

When creating datagram to send into UDP socket, it must be specified the following:

A

Destination IP address
Destination Port

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

Ports

A

Ports are numerical identifiers used by the transport layer to specify not just the host, but the particular process or service within the host that should receive the data. Think of a port as an apartment number in a large building: the street address gets you to the building, and the apartment number ensures you reach the right unit inside

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

Sockets

A

A socket, on the other hand, is an endpoint in a network communication. Sockets are created and used in software to send and receive data across a network. They combine an IP address and a port number so that a unique connection is established between one specific process on a device and another on a different device. Essentially, a socket is what allows a network to establish a connection through which data can be sent and received between processes.

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

Reliability Mechanisms in TCP

A

TCP is designed to offer reliable communication that ensures data is delivered accurately and in order, regardless of network conditions.

Here are some of the key mechanisms it uses: Error Detection and Recovery

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

Error Detection and Recovery

A

TCP uses a variety of techniques for error detection and recovery:

  • Checksums to detect errors in data that is transmitted over the network. If a segment’s data is changed during transit, the calculated checksum at the receiver will not match the checksum in the segment header, indicating a problem.
  • Sequence numbers to keep track of the order of segments and ensure they are assembled in the correct sequence at the destination.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Acknowledgments and Retransmissions

A

TCP uses acknowledgments to confirm the receipt of packets. When a sender transmits data, it starts a timer expecting to receive an acknowledgment of receipt from the receiver. If the acknowledgment is not received before the timer expires, TCP assumes the packet was lost or corrupted and retransmits it. This ensures that no data is lost in transit.

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

Flow Control

A

Flow control is managed using the window size, which controls how much data can be in transit before needing an acknowledgment. This prevents a fast sender from overwhelming a slow receiver, which might not be able to process all incoming data promptly

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

Congestion Control

A

Congestion control mechanisms like Slow Start, Congestion Avoidance, Fast Retransmit, and Fast Recovery are implemented to manage data flow in the network based on current network conditions, helping to minimize network congestion and ensure data delivery even under heavy load conditions.

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

Multiplexing at sender

A

handle data from multiple
sockets, add transport header
(later used for demultiplexing)

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

Demultiplexing at receiver

A

Use header info to deliver
received segments to correct
socket

16
Q

How demultiplexing works

A

Host receives IP datagrams
* each datagram has source IP
address, destination IP address
* each datagram carries one
transport-layer segment
* each segment has source,
destination port number
Host uses IP addresses & port
numbers to direct segment to
appropriate socket

17
Q

Ephemeral Ports

A
  • Client initiates application data transfers using TCP and UDP using well-known port number as the destination port number.
  • to know where to send the reply, server must know the port number the client is using.
  • Client supplies the port number as the source port in the request
  • Server uses the source port as the
    destination port to send the reply.
  • Client doesn’t use well-known port
    numbers.
  • Client is assigned a temporary port number called an ephemeral port number
18
Q

Connection-oriented demultiplexing

A
  • TCP socket identified by
    4-tuple:
  • source IP address
  • source port number
  • dest IP address
  • dest port number
    Receiver uses all four
    values to direct segment
    to appropriate socket
  • Server may support many
    simultaneous TCP sockets:
  • each socket identified by its
    own 4-tuple
  • each socket associated with
    a different connecting client
19
Q

UDP checksum
Goal: detect errors (i.e., flipped bits) in transmitted segment

A

sender:
▪ treat contents of UDP
segment as sequence of 16-
bit integers.
checksum: addition (one’s
complement sum) of
segment content
▪ checksum value put into
UDP checksum field

receiver:
- all four 16-bit words are added,
including the checksum
- if sum is not 1111111111111111,
* error detected

if equal
* no error detected
* But maybe errors nonetheless?