]> git.ipfire.org Git - thirdparty/suricata.git/commit
frames: do not only rely on FRAME_STREAM_ID 11789/head
authorPhilippe Antoine <pantoine@oisf.net>
Thu, 12 Sep 2024 11:07:48 +0000 (13:07 +0200)
committerVictor Julien <victor@inliniac.net>
Tue, 17 Sep 2024 20:16:42 +0000 (22:16 +0200)
commit50ee5e09c73147f439f342b8ea40c144bd717d5e
treea0bc066695f4a83bf2a1839193b57649c9888fd9
parent9571df8936e071ed82cbd72beb1891ec04de923d
frames: do not only rely on FRAME_STREAM_ID

As stream frame is not always created,
hence the first frame is not always a stream frame :
If stream frame is not enabled, it does not get created,
and other enabled frames may be created first.
See use of FrameConfigTypeIsEnabled

This resulted that this other frame got its length updated
on stream end, which led to false positives.

Also checking FRAME_STREAM_TYPE is more consistent.

Not a clean cherry-pick as AppLayerFrameGetLastOpenByType
does not exist in main7

Ticket: 7213
src/app-layer-frames.h
src/app-layer-parser.c