N5.1 TCP Flashcards

1
Q

What layer of the internet model are TCP and UDP protocols used in?

A

Transport Layer

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

What are TCP packets called?

A

Segments

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

Is TCP connection-oriented or connection-less?

A

Connection-oriented
(ordered, confirmed, reliable)
- byte stream service (treats segments like a byte stream)

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

What does TCP stand for?

A

Transmission Control Protocol

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

What does UDP stand for?

A

User Datagram Protocol

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

What addressing do TCP and UDP use?

A

Port numbers

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

Describe a TCP connection set-up (3 way handshake)

A

Connection set-up

  • Client: active open (looking for server connection)
  • Client sends SYN
  • Server (passive open): listening for connection
  • Server acknowledges connection request (SYN ACK)
  • Client opens socket at Local Connection Name
  • Sends SYN ACK
  • Server accepts and connects on Local Connection Name
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Describe a TCP connection tear-down

A

Connection tear-down

  • user A sends close request (FIN)
  • user B acknowledges (FIN ACK)
  • user B sends remaining data and ACKs
  • user B sends FIN
  • user A sends FIN ACK and waits for a number of seconds before close
  • user B closes.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Give a TCP security precaution for sequence numbers

A

Use a random sequence number to start byte stream -not zero because its too predictable and packets could be faked.

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

What is the transport layer 5-tuple?

A

A - IP Address
P - Transport Layer Port Number

Each unique 5-tuple is a unique flow

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

Describe server port numbers for TCP

A
  • well-known
  • assigned
  • server listens on well-known port for clients to connect
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Describe client port numbers for TCP

A
  • Ephemeral
  • Allocated by OS
  • Connections to same server will have different client port numbers
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Give examples of TCP’s reliability

A
  • Sequence numbers: maintain ordering of segments
  • Acknowledgement: next expected sequence number at receiver given in TCP header
  • Sender has a re-transmission strategy
  • Checksum: uses pseudo header, checksum re-evaluated at receiver, bad checksum means packet discarded
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Possible reliability strategies:

Describe the single packet (Idle-RQ) strategy.

A

Single packet (Idle-RQ) strategy

  • send and wait
  • sends one packet then waits for an ACK before sending next packet
  • simple to implement but inefficient
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Possible reliability strategies:

Describe the multiple packets (Continuous-RQ) strategy.

A

Multiple packets (Continuous-RQ) strategy.

  • Transmitter sends as many packets as it can (finite number before it must wait for an ACK)
  • Receiver sends ACKs as packets arrive
  • Transmitter can resend any missing packet if no acknowledgement arrives
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Transport-Layer Congestion

List the possible causes of congestion.

A

Causes of congestion

  • too many packets
  • buffer overflow in routers
  • unpredictable traffic patterns
  • route changes
  • time-of-day traffic
17
Q

Transport-Layer Congestion

List the possible effects of congestion.

A

Effects of congestion

  • higher end-to-end delay
  • lost packets
  • network instability
  • loss of service
18
Q

Describe the strategy for TCP congestion control

A

Slow start:
send 1 segment, if successfully ACK’d then send 2 segments, then 4, then 8 etc. (doubles for each ACK)
Congestion avoidance:
if an ACK is missing/delayed, then drop to half as many segments sent and start to increase number linearly
Transmitter uses RTT to monitor how busy network is

19
Q

What is RTT?

A

RTT - Round Trip Time
Time for an acknowledgement to be received by the transmitter for a packet sent out.
Used in congestion-avoidance to monitor how busy network is.

20
Q

What is flow control for TCP?

A
  • end-to-end signal from the receiver

- explicit control from the receiver

21
Q

Is TCP secure? Why/why not?

A

No TCP is not secure

TCP transmissions are not protected from inspection, forgery, modification or replay.

22
Q

Problems with TCP

A
  • security

- delay