Sunteți pe pagina 1din 16

Transport Layer Protocols

HUAWEI TECHNOLOGIES CO., LTD.


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 networks. The characteristics of data, such as sensitivity to
delay and the need for reliability often determines the protocols used at
the transport layer. This section focuses on the knowledge of how such
characteristics are supported through the behavior of each protocol.

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 2
Objectives

Upon completion of this section, trainees 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.

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 3
Transmission Control Protocol

Host A TCP Connection Host B

Request Reply

 A connection is established before data is sent.

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 4
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.

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 5
TCP Header

0 15 31

Source Port Destination Port

Sequence Number

20bytes Acknowledge Number

Header Resv N C E U A P R S F
Window
Length . SW CRCSS Y I
R EGKHT NN

Checksum Urgent Pointer

Options Padding

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 6
TCP Connection Establishment

Host A Server A

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

C K , A CK)
S YN,A =SYN
nd TL
Se k=a+1,C
ac
eq =b,
(s
Se
(seq nd A
=a+ CK
1,ac
k =b+
1, C
TL=
A CK)

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

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 7
TCP Transmission Process

Host A Server A

Send 1,2,3

Acknowledge 4
Send 4,5,6

Acknowledge 4
Send 4,5,6

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 9
TCP Flow Control

Host A length 1 Server A


0 24 window
length 1 40 9 6
024 window
4 09 6

4 8
0 49 window 20
ack 2

length 1
024 window
length 1 4 09 6
024 window
4 09 6

048
window 2
ack 4097

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

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 10
TCP Connection Termination

Host A Server A
 FIN

K
 AC

 FIN

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

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

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 11
User Datagram Protocol

Host A Host B

Request Reply

 UDP based data is sent without establishing a connection.

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 12
UDP Datagram Format

UDP

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.
Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 13
UDP Forwarding Behavior

Host A Host B

 UDP susceptible to the possibility of datagram duplication or


non-orderly delivery of datagrams.
Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 14
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.
Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 15
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?

Copyright © 2013 Huawei Technologies Co., Ltd. All rights reserved. Page 16
Thank you
www.huawei.com

S-ar putea să vă placă și