From: Masud Hasan (mashasan) Date: Wed, 16 Jun 2021 20:42:37 +0000 (+0000) Subject: Merge pull request #2941 in SNORT/snort3 from ~SMINUT/snort3:is_ack_valid to master X-Git-Tag: 3.1.7.0~12 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9941aa2b3492d7b6565621caaf8db6af3ed04878;p=thirdparty%2Fsnort3.git Merge pull request #2941 in SNORT/snort3 from ~SMINUT/snort3:is_ack_valid to master Squashed commit of the following: commit c1f81f31a14a16a57e4addc67ea971f39d43f9e5 Author: Silviu Minut Date: Thu Jun 10 17:15:12 2021 -0400 stream: fix is_ack_valid to return true even when current ack is to the left of snd_una, per RFC793 --- diff --git a/src/stream/tcp/tcp_stream_tracker.h b/src/stream/tcp/tcp_stream_tracker.h index 0945f2ea8..1bc7f6b95 100644 --- a/src/stream/tcp/tcp_stream_tracker.h +++ b/src/stream/tcp/tcp_stream_tracker.h @@ -194,7 +194,7 @@ public: if ( ( snd_una == 0 ) && ( snd_nxt == 0 ) ) return true; - bool valid = SEQ_GEQ(cur, snd_una) && SEQ_LEQ(cur, snd_nxt); + bool valid = SEQ_LEQ(cur, snd_nxt); if ( !valid ) tcpStats.invalid_ack++;