doc: clarify RST handling comment

This clarifies the documentation around RST handling to document
the approach follows RFC 5961 and is not a standards violation
This commit is contained in:
Joel Cunningham 2017-04-21 09:24:08 -05:00
parent f4730e78f8
commit ad779e5c9c

View File

@ -711,10 +711,10 @@ tcp_process(struct tcp_pcb *pcb)
acceptable = 1; acceptable = 1;
} else if (TCP_SEQ_BETWEEN(seqno, pcb->rcv_nxt, } else if (TCP_SEQ_BETWEEN(seqno, pcb->rcv_nxt,
pcb->rcv_nxt + pcb->rcv_wnd)) { pcb->rcv_nxt + pcb->rcv_wnd)) {
/* If the sequence number is inside the window, we only send an ACK /* If the sequence number is inside the window, we send a challenge ACK
and wait for a re-send with matching sequence number. and wait for a re-send with matching sequence number.
This violates RFC 793, but is required to protection against This follows RFC 5961 section 3.2 and addresses CVE-2004-0230
CVE-2004-0230 (RST spoofing attack). */ (RST spoofing attack), which is present in RFC 793 RST handling. */
tcp_ack_now(pcb); tcp_ack_now(pcb);
} }
} }