From 18c923318a1c4fa30e74dd802748cf94246e77c6 Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Tue, 29 Jun 2010 19:21:12 +0200 Subject: [PATCH] Fix bug where valid FIN packets would be rejected. --- src/stream-tcp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/stream-tcp.c b/src/stream-tcp.c index 8f6ddf8b98..8d8cf1f30f 100644 --- a/src/stream-tcp.c +++ b/src/stream-tcp.c @@ -1871,9 +1871,9 @@ static int StreamTcpPacketStateFinWait1(ThreadVars *tv, Packet *p, "%" PRIu32 ", ACK %" PRIu32 "", ssn, p->payload_len, TCP_GET_SEQ(p), TCP_GET_ACK(p)); - if (SEQ_LT(TCP_GET_SEQ(p), ssn->client.next_seq || + if (SEQ_LT(TCP_GET_SEQ(p), ssn->client.next_seq) || SEQ_GT(TCP_GET_SEQ(p), (ssn->client.last_ack + - ssn->client.window)))) + ssn->client.window))) { SCLogDebug("ssn %p: -> SEQ mismatch, packet SEQ %" PRIu32 "" " != %" PRIu32 " from stream", ssn,