Chap 20 TCP Estab
Chap 20 TCP Estab
Chap 20 TCP Estab
11/30/2011
11/30/2011
Connection Termination
either or both sides by mutual agreement
graceful or abrupt termination
if graceful, initiator must:
send FIN to other end, requesting termination
place connection in FIN WAIT state
when FIN received, inform user and close connection
Connection Establishment
two way handshake
A send SYN, B replies with SYN
lost SYN handled by re-transmission
ignore duplicate SYNs once connected
11/30/2011
Two Way
Handshake:
Obsolete
Data
Segment
Solution: starting SN is far away
from the last SN of the previous
connection.
Use request of the form SYNi
where i +1 is the SN of the first
data segment to be sent.
7
11/30/2011
TCP Three
Way
Handshake:
State
Diagram
TCP Three
Way
Handshake:
Examples
10
11/30/2011
11
11/30/2011
Connection Termination:
Graceful Close
also have problems with loss of segments and
obsolete segments
need graceful close which will:
send FIN i and receive AN i+1
receive FIN j and send AN j+1
wait twice maximum expected segment
lifetime
13
Reading
Chapter 20, Stallings book
14