liveBook · Manning

Three-way handshake

As explained in Acing the CCNA Exam: Volume 1 Fundamentals and Protocols

A three-way handshake is a three-message exchange used by TCP hosts to establish a connection before transmitting application data.

The three-way handshake establishes a TCP connection before application data is transmitted. It uses TCP header flags to coordinate both hosts. section 22.2.1

Follow the three-message sequence:

  • SYN: The initiating host requests a connection and synchronizes its initial sequence number. section 22.2.1 section 22.3
  • SYN-ACK: The receiving host acknowledges the request and sends its own synchronization information. section 22.2.1
  • ACK: The initiating host acknowledges the response; the TCP connection is ready for data exchange. section 22.2.1 section 22.3

PC1 connects to SRV1

PC1 sends a TCP segment with SYN, SRV1 replies with SYN-ACK, and PC1 returns ACK. These three establishment segments carry no application data; they prepare the connection for later exchange. section 22.2.1

The handshake adds time and processing overhead compared with UDP, which sends data without first establishing a connection. TCP trades that overhead for connection-oriented, reliable communication and flow control. section 22.2.3

How Acing the CCNA Exam: Volume 1 Fundamentals and Protocols covers it

How deep it goes
Explains the three messages, TCP flags, empty segments, and initial sequence numbers without detailing lower-level implementation.
Examples
Uses a PC1-to-SRV1 exchange and a SYN, SYN-ACK, ACK sequence diagram.
What you can do after
Evaluate/understand TCP connection setup and distinguish its startup overhead from UDP transmission.
How it connects
Connects TCP flags, sequence numbers, acknowledgment numbers, reliable communication, flow control, connection termination, and UDP.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Acing the CCNA Exam: Volume 1 Fundamentals and Protocols. The section links point to the parts of the book it draws on.