Sunday, July 15, 2012

TCP Connection Establishment: 3 Way Handshake

A TCP Connection is established between two peers before any data is transferred between them. The mechanism in which the TCP connection is established is famously termed as 3 way Handshake.



The 3 Way Handshake:

Step #1:
When the Server is in READY-TO-ACCEPT a connection, the client performs an ACTIVE-OPEN, creating by sending a SYN message to the server. The client then waits to receive an ACK for its SYN request, as well as expects to receive the Server's SYN.

Step #2:
After receiving the SYN from the client, the Server sends a single SYN+ACK message back to the client that contains an ACK for the client's SYN, and the server's own SYN.

Step #3:
The client receives the Server's SYN+ACK packet. It sends the server an ACK for the Server's SYN.

A successful TCP Connection is Established.

No comments:

Post a Comment