]> git.ipfire.org Git - thirdparty/suricata.git/commit
detect/frames: fix crash when parsing bad rule
authorVictor Julien <vjulien@oisf.net>
Mon, 24 Jan 2022 22:30:51 +0000 (23:30 +0100)
committerVictor Julien <vjulien@oisf.net>
Tue, 25 Jan 2022 07:16:00 +0000 (08:16 +0100)
commite902aaf838acb552350078070092a2c61b918b19
tree7031327f9eab68b71506bb1b9f9104b05d5896f6
parentc6be6d2c6fa89e3a0a9326b001972e8e1e9155ab
detect/frames: fix crash when parsing bad rule

Indexing of Signature::init_data::smlists would fail for a rule that
used a frame w/o content, as the array would only be expanded when
adding a content. Adding a check to see if there list id is in bounds
is an implicit check for the "no content" case.

Bug #5011.
src/detect-parse.c