mirror of https://github.com/OISF/suricata
flow: make TCP reuse handling in flow engine optional
In case of autofp (or more general, when flow and stream engine run in different threads) the flow engine should not trigger a flow reuse as this can lead to race conditions between the flow and the stream engine. In such cases, the flow engine can be far ahead of the stream engine as packets are in a queue between the threads. Observed: Flow engine tags packet 10 as start of new flow. Flow is tagged as 'reused'. Stream engine evaluates packet 5 which belongs to the old flow. It rejects the flow as it's tagged 'reused'. Attaches packet 5 to the new flow which is wrong. Solution: This patch connects the flow engines handling of reuse cases to the runmode. It hooks into the RunmodeSetFlowStreamAsync() call to notify the flow engine that it shouldn't handle the reuse.pull/1342/head
parent
d78be75b9f
commit
7426a9c645
Loading…
Reference in New Issue