Simultaneous connect, close #159
-
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
For SEQ# and ACK# for simultaneous connection see: KENSv3/Documentation/rfc/rfc793.txt Lines 2075 to 2093 in eba97b6
It seems a bug in the reference TCP implementation. You can ignore it.
The SEQ# is randomly assigned for security. It is a common practice in the real TCP networking stacks.
The FIN packets increase SEQ# by 1. See: KENSv3/Documentation/rfc/rfc793.txt Lines 2484 to 2526 in eba97b6
I cannot understand what are you asking. If you meant how to decide SEQ# and ACK#, read: KENSv3/Documentation/rfc/rfc793.txt Line 1597 in eba97b6
BeforeAccept is normal close, and AfterAccept is simultaneous close.
Since you have received SYN before sending SYN/ACK, you have already know peer's SEQ#, so you can use it to decide ACK#. |
Beta Was this translation helpful? Give feedback.
For SEQ# and ACK# for simultaneous connection see:
KENSv3/Documentation/rfc/rfc793.txt
Lines 2075 to 2093 in eba97b6