You are on page 1of 16

Transport Layer Protocols

Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.


Foreword
 The transport layer is associated with the end-to-end behavior of transport
layer protocols that are defined once data reaches the intended destination
. TCP and UDP represent the protocols commonly supported within IP netw
orks. The characteristics of data, such as sensitivity to delay and the need f
or reliability often determines the protocols used at the transport layer. Thi
s section focuses on the knowledge of how such characteristics are support
ed through the behavior of each protocol.

age 2 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
Objectives
 Upon completion of this section, you will be able to:
 Describe the common differences between TCP and UDP.
 Describe the forms of data to which TCP and UDP are applied.
 Identify well known TCP and UDP based port numbers.

age 3 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
Transmission Control Protocol

Host A TCP Connection Host B

Request Reply

 A connection is established before data is sent.

age 4 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
TCP Ports
Host A HTTP Server

S:1027 D:80 Data S:80 D:1027 Data

Protocol Port
FTP 20 - 21
HTTP 80
TELNET 23
SMTP 25

 Ports represent individual services such as those listed above.

age 5 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
TCP Header

IP TCP Header Data

0 15 31

Source Port Destination Port

Sequence Number

20bytes Acknowledge Number

Header NC E U A P R S F
Resv. S W C R C S S Y I Window
Length R E G K HT NN

Checksum Urgent Pointer

Options Padding

age 6 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
TCP Connection Establishment
Host A Server A

Send S
YN
(seq=a
,CTL=S
YN )

,A CK)
K Y N
Y N ,AC CTL=S
S end
S
= a + 1,
 ck
= b,a
(seq
S e
(seq nd
=a + ACK
1 , ac
k=b
+1 ,CT
L=A
CK)

 A TCP connection is established after a three-way handshake.

age 7 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
TCP Transmission Process
Host A Server A

Send 1,2,3

Acknowledge 4
Send 4,5,6

Acknowledge 4
Send 4,5,6

age 8 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
TCP Flow Control

Host A length Server A


1024
window
length 40 9 6
1 0 24
window
40 9 6

2048
2 0 49 window
a c k

length
1 02 4
length window
1 0 24 4096
window
40 9 6

204 8
window
ack 40 97

length
1024
window
length 4 0 96
1024
window
4 0 96

age 9 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
TCP Connection Termination

Host A Server A
 FIN

K
 AC

 FIN
TIME_WAIT 2x MSL ACK
(MSL = 2 minutes)
. Closed
.

Closed

 Host A will ensure ACK is received by Server A before closing.

age 10 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
User Datagram Protocol

Host A Host B

Request Reply

 UDP based data is sent without establishing a connection.

age 11 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
UDP Datagram Format

IP UDP Data

0 15 16
31
Source port Destination port
8 bytes
Length Checksum

 UDP achieves minimal overhead for each datagram.


 Datagram delivery is not guaranteed with UDP.

age 12 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
UDP Forwarding Behavior

Host A Host B

 UDP susceptible to the possibility of datagram duplication or non-orderly d


elivery of datagrams.

age 13 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
UDP Forwarding Behavior

Host A Host B
Voice/Video

Packet Loss

 There are no acknowledgements, therefore lost packets are not retransmitted,


this however is beneficial to delay sensitive data.

age 14 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
Summary
 What is the purpose of the acknowledgement field in the TCP header?
 Which TCP code bits are involved in a TCP three-way handshake?

age 15 Copyright © 2019 Huawei Technologies Co., Ltd. All rights reserved.
Thank You
www.huawei.com

You might also like