当前位置:网站首页>TCP's three handshakes and four waves (brief introduction)
TCP's three handshakes and four waves (brief introduction)
2022-07-27 02:15:00 【Not smart】
TCP brief introduction :
Transmission control protocol -- Connection oriented reliable transport protocol
After completing the basic work of the transport layer , It also needs to further ensure the reliability of transmission . and UDP The difference is ,TCP It provides reliable connection oriented transmission services , It also provides functions such as flow control .
TCP The main identification mark bit in the message format

1.SYN Synchronization flag bit ,SYN = 1, This data packet represents the connection data packet between the client and the server .
2.ACK Confirm the flag bit ,ACK = 1, This data packet is a reply packet , Used to confirm received packets .
3.FIN End tag bit ,FIN = 1, It shows that this is a data packet that ends the connection unilaterally .
Three handshakes
The first handshake : Establishing a connection Among the messages sent by the client to the server SYN position Set to 1, Indicates a request to establish a connection with the server .
The second handshake : Server received SYN Message segment The server receives the connection request message from the client , Then it sends a connection establishment request to the client and responds to the connection request sent by the client , In this case, the server sends messages to the client SYN position and ACK position Are set to 1.
The third handshake : Client receives server's SYN+ACK Message segment After the client receives the message from the server , It is known that the server has received the connection establishment request sent by itself , And ask to establish a connection with yourself , Finally, the client responds to the message sent by the server .
Four waves
First wave : The client is ready to disconnect Among the messages sent by the client to the server FIN position Set to 1, Indicates a request to disconnect from the server .
Second wave : Server received FIN Message segment The server responds to the disconnection request sent by the client , Return the confirmation response package (ACK Message segment ).
Third wave : Server send FIN Message segment Request close connection The server received a request from the client to disconnect , And there is no data to send to the client , The server will send a disconnect request to the client .
Fourth wave : The client sends to the server ACK Message segment The client responds to the disconnection request sent by the server , Send to the server ACK Message segment , The server will shut down directly after receiving , The client waits 2MSL After closing .
MSL refer to ( Maxium Segement Lifetime), Maximum message lifetime . When the client receives FIN After package , Will wait for 2MSL Time , If in 2MSL Within time , I didn't receive it again FIN The package will shut down the client .
Popular speaking
Three handshakes
A: Do you want to have an appointment? ?
B: about , Do you have an appointment ?
A: about .( Connection established successfully )
Four waves
A: I am afraid that l have to go .
B: Um. , got it , Wait for me to say two more words .
B: That's it , You can leave now. .
A: go .( Successfully disconnected )
边栏推荐
- 2022zui新抖音24小时循环值守直播监控(一)直播间开播监控
- 2022年最新文本生成图像研究 开源工作速览(Papers with code)
- 6.30联发科笔试
- FID index reproduction step on the pit to avoid the pit text generation image FID quantitative experiment whole process reproduction (FR é Chet inception distance) quantitative evaluation experiment s
- STM32入门教程第一讲
- --Project summary
- C语言实现小游戏【三子棋】注释详细 逻辑清晰 快来看看吧!!
- uuid和索引建立规则
- [Database Course Design] SQLSERVER database course design (student dormitory management), course design report + source code + database diagram
- OSPF在MGRE环境下的实验
猜你喜欢

Beyond hidden display ellipsis

【mysql】mysql启动关闭命令以及一些报错解决问题
![[reprint] GPU compute capability table](/img/7c/87be1131f52f21fe080c36f0834467.png)
[reprint] GPU compute capability table

FID指标复现踩坑避坑 文本生成图像FID定量实验全流程复现(Fréchet Inception Distance )定量评价实验踩坑避坑流程

FID index reproduction step on the pit to avoid the pit text generation image FID quantitative experiment whole process reproduction (FR é Chet inception distance) quantitative evaluation experiment s

Text to image论文精读GR-GAN:逐步细化文本到图像生成 GRADUAL REFINEMENT TEXT-TO-IMAGE GENERATION

HCIA基础知识(1)

OSPF静态大实验
![[explain C language in detail] this article takes you to know C language and makes you impressed](/img/37/205c1c6eb2ba704941e48ff89c6268.png)
[explain C language in detail] this article takes you to know C language and makes you impressed

超出隐藏显示省略号
随机推荐
JS——初识JS、变量的命名规则,数据类型
6.28 Dahua written examination
Fastjson handles string escape characters
Text to image论文精读GR-GAN:逐步细化文本到图像生成 GRADUAL REFINEMENT TEXT-TO-IMAGE GENERATION
Is index reproduction text generation image is score quantitative experiment whole process reproduction inception score quantitative evaluation experiment step on the pit and avoid the pit process
OSPF static experiment
ACM模式输入输出练习
RIP V2 的简单应用(v2的配置、宣告、手工汇总、RIPV2的认证、沉默接口、加快收敛)
6.30 didi surface warp (one side + two sides)
C语言实现小游戏【三子棋】注释详细 逻辑清晰 快来看看吧!!
解决方案:Win10如何使用bash批处理命令
IS指标复现 文本生成图像IS分数定量实验全流程复现 Inception Score定量评价实验踩坑避坑流程
OSPF在MGRE环境下的实验
FID index reproduction step on the pit to avoid the pit text generation image FID quantitative experiment whole process reproduction (FR é Chet inception distance) quantitative evaluation experiment s
7.7 SHEIN希音笔试
2022最新抖音直播监控(二)直播间流媒体下载
2022zui new Tiktok 24-hour round robin live broadcast monitoring (I) live broadcast room start-up monitoring
Flink1.13.6 detailed deployment method
静态路由缺省路由vlan实验
[volatile principle] volatile principle