mirror of
https://github.com/bol-van/zapret.git
synced 2025-05-01 19:32:59 +03:00
nfqws: conntrack: do not reset entry on dup SA
This commit is contained in:
parent
d2c9ff50cd
commit
68a538daed
@ -143,8 +143,11 @@ static void ConntrackFeedPacket(t_ctrack *t, bool bReverse, const struct tcphdr
|
|||||||
}
|
}
|
||||||
else if (tcp_synack_segment(tcphdr))
|
else if (tcp_synack_segment(tcphdr))
|
||||||
{
|
{
|
||||||
if (t->state!=SYN) ConntrackReInitTrack(t); // erase current entry
|
// ignore SA dups
|
||||||
if (!t->seq0) t->seq0 = ntohl(tcphdr->th_ack)-1;
|
uint32_t seq0 = ntohl(tcphdr->th_ack)-1;
|
||||||
|
if (t->state!=SYN && t->seq0!=seq0)
|
||||||
|
ConntrackReInitTrack(t); // erase current entry
|
||||||
|
if (!t->seq0) t->seq0 = seq0;
|
||||||
t->ack0 = ntohl(tcphdr->th_seq);
|
t->ack0 = ntohl(tcphdr->th_seq);
|
||||||
}
|
}
|
||||||
else if (tcphdr->th_flags & (TH_FIN|TH_RST))
|
else if (tcphdr->th_flags & (TH_FIN|TH_RST))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user