Get the App
SLTechnology News&Howtos  ›  Network Security  › 

Three-way handshake and four disconnects (easy to understand version)

Shulou Source: shulou.com Published: 2022-06-01 07:57:52 10月02日 Update

In production work, three-time handshake and four-time disconnection of these knowledge is common sense, but due to some data problems, it is more difficult for beginners to understand. I will write it for you today. I am learning some personal understanding of the four disconnections of the three-way handshake. If there are any mistakes, I hope you can correct them a lot. Thank you!

Three handshakes and four disconnections can be understood as a children's song that we used to listen to when we were young.

Draw up the scene: child (client) police uncle (server)

When children go to the police, their uncle will send out a syn prompt.

When the police uncle receives the response from the child, he will send a prompt of syn and ack.

The child gave the money (ack,seq) to the police uncle.

Uncle nodded his head and said goodbye (fin)

Children say goodbye (fin).

Here are the flags and serial numbers for the three-way handshake and four disconnections.

Client establish connection flag syn serial number seq=0

The server received a connection reply: syn and ack serial number seq=0 ack=1

Confirm that the package is ack serial number seq=1ack=1

Fin disconnected

Rst re-establish connection

Such a tag is generated only when p/push transfers data.

Protocol pop3

Tags: Children uncles sequences serial numbers police clients clients servers flags prompts services personal nursery songs beginners scenes hours childhood common sense headers data Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Information Xiaomi Apple MariaDB Linux