X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvnet%2Ftcp%2Ftcp_input.c;h=395943739e832b49b40183eccbe03c9bcca88820;hb=4850e3e73c61830516ac9ccb22976be685bea3b5;hp=f04fa5d890121cd9bf700b0672ac324b7ce2f5ac;hpb=42ceddb7cd836a89a12b0b8e623b06bc4c0cc0cb;p=vpp.git diff --git a/src/vnet/tcp/tcp_input.c b/src/vnet/tcp/tcp_input.c index f04fa5d8901..395943739e8 100644 --- a/src/vnet/tcp/tcp_input.c +++ b/src/vnet/tcp/tcp_input.c @@ -2724,6 +2724,14 @@ tcp46_rcv_process_inline (vlib_main_t * vm, vlib_node_runtime_t * node, goto drop; } + /* Make sure the ack is exactly right */ + if (tc0->rcv_nxt != vnet_buffer (b0)->tcp.seq_number) + { + error0 = TCP_ERROR_SEGMENT_INVALID; + tcp_send_reset_w_pkt (tc0, b0, is_ip4); + goto drop; + } + /* Update rtt and rto */ tcp_estimate_initial_rtt (tc0);