Bug #4645
closedTCP reassembly, failed assert app_progress > last_ack_abs, both sides need to be pruned
Description
Found by oss-fuzz
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=35626
Minimized reproducer with suricata is./src/suricata -r lolb.pcap -k none -c suricata.yaml --set stream.midstream=true
What happens is
- first packet (midstream) all ok (ack = 1)
- second packet, from the other side, ack is ok, but sequence indicates a gap from first packet ack (seq = 77)
- third packet, sequence ok, ack is increased since first packet confirming the gap (ack = 77) StreamTcpUpdateAppLayerProgress
is called by AppLayerHandleTCPData
at the end of if (flags & STREAM_GAP) {
- Fourth packet is in first direction (seq and ack meaningless)
At the end of third packet, the 76 gap does not get subtracted in app_progress_rel
as StreamTcpPruneSession
only considers the other stream
Files
Updated by Jeff Lucovsky over 3 years ago
- Copied from Bug #4549: TCP reassembly, failed assert app_progress > last_ack_abs, both sides need to be pruned added
Updated by Victor Julien about 3 years ago
- Status changed from Assigned to Closed
Updated by Shivani Bhardwaj over 2 years ago
- Status changed from Closed to Assigned
- Target version changed from 6.0.4 to 6.0.6
Updated by Jeff Lucovsky over 2 years ago
- Status changed from Assigned to In Progress
- Assignee changed from Shivani Bhardwaj to Jeff Lucovsky
Cherry-pick commit(s):
- 1f43e1477f3c
- 3d6e733aa729
Updated by Jeff Lucovsky over 2 years ago
- Status changed from In Progress to In Review
Updated by Jeff Lucovsky over 2 years ago
Updated by Jeff Lucovsky over 2 years ago
- Status changed from In Review to Closed