我通过以下方式创建了TCP同时打开的情况:
10.10.200.147
上 while [ 1 -gt 0 ]; do nc -p 9999 192.168.26.48 9988; done
192.168.26.48
上 while [ 1 -gt 0 ]; do nc -p 9988 10.10.200.147 9999; done
tcpdump捕获了交换的数据包:
51.862896 IP 192.168.26.48.9988 > 10.10.200.147.9999: Flags [S], seq 4166633388, win 29200, options [mss 1460,sackOK,TS val 194268310 ecr 0,nop,wscale 7], length 0
51.863015 IP 10.10.200.147.9999 > 192.168.26.48.9988: Flags [S], seq 4232161722, win 29200, options [mss 1460,sackOK,TS val 2026928779 ecr 0,nop,wscale 7], length 0
51.863034 IP 192.168.26.48.9988 > 10.10.200.147.9999: Flags [S.], seq 4166633388, ack 4232161723, win 29200, options [mss 1460,sackOK,TS val 194268310 ecr 2026928779,nop,wscale 7], length 0
51.863126 IP 10.10.200.147.9999 > 192.168.26.48.9988: Flags [S.], seq 4232161722, ack 4166633389, win 29200, options [mss 1460,sackOK,TS val 2026928779 ecr 194268310,nop,wscale 7], length 0
51.863135 IP 192.168.26.48.9988 > 10.10.200.147.9999: Flags [.], ack 4232161723, win 229, options [nop,nop,TS val 194268310 ecr 2026928779], length 0
51.863278 IP 10.10.200.147.9999 > 192.168.26.48.9988: Flags [.], ack 4166633389, win 229, options [nop,nop,TS val 2026928779 ecr 194268310], length 0
这与下面的图像相对应(稍有不同-该图像未显示最后的ACK交换!):
但是!! TCP状态转换图不显示有关同时打开的从SYN_RCVD
到ESTABLISHED
的转换。
从SYN_RCVD
到ESTABLISHED
之间应该有一条连续线,内容为:
接收:ACK /发送:ACK
是正确的吗?