Results 1 to 1 of 1
Hi, I am new to network programming !!! I have written a simple Daytime Client/Server Program to see how sockets work and to understand the TCP 3-way handshake and 4 ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 09-14-2006 #1
- Join Date
- Sep 2006
TCP FIN Message Query !!!
I am new to network programming !!! I have written a simple Daytime Client/Server Program to see how sockets work and to understand the TCP 3-way handshake and 4 way teardown of a connection. I used ETHEREAL DUMP to see the messages.
The book I am referring says that first either Server or client sends a FIN message after data transfer is complete and then it is acknowledged by an ACK message which has an acknowledgment value of 1 greater than the SEQUENCE value sent in the initial FIN Message.
However, the Sequence number in the initial FIN Message and the acknowledgment number in the ACK message are the same. The Ethereal dump shown is as follows :
----- Snip from ETHEREAL DUMP -----------
13 > 38059 [FIN, ACK] Seq=3806002358 Ack=3801859453 Win=32767 ......
38059 > 13 [ACK] Seq=3801859453 Ack=3806002358 Win=32767 ......
38059 > 13 [FIN, ACK] Seq=3801859453 Ack=3806002359 Win=32767 ......
13 > 38059 [ACK] Seq=3806002359 Ack=3801859454 Win=32767 ......
------- Snip --------------
From the above cited snippet, we can see that for the bottom 2 FIN/ACK messages, the Seq and Ack numbers are incremented, whereas for the top two messages, its not. So kindly enlighten me why this is happening !!! Thanks in advance.