简体   繁体   中英

Can a TCP packet with the FIN flag also have data?

I'm working on a packet capture program. Is it possible for TCP packet to have the FIN flag set but also have data?

Strictly speaking, it is possible to put data in a TCP FIN packet... Quoting from RFC 793 (emphasis mine):

The SYN and FIN are the only controls requiring this protection, and these controls are used only at connection opening and closing. For sequence number purposes, the SYN is considered to occur before the first actual data octet of the segment in which it occurs, while the FIN is considered to occur after the last actual data octet in a segment in which it occurs .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM