]> git.ipfire.org Git - thirdparty/suricata.git/commit
sip/parser: enforce valid chars for sip version
authorGiuseppe Longo <giuseppe@glongo.it>
Sat, 25 Nov 2023 08:39:54 +0000 (09:39 +0100)
committerVictor Julien <victor@inliniac.net>
Wed, 28 Feb 2024 06:00:43 +0000 (07:00 +0100)
commit69f841c9981147f55ec9f76d44f7ac138e726304
tree53bbc3f230f456f000a30f24571df2e2a4ac9df3
parent7e993d5081c35d62eada429bad43430417267e5a
sip/parser: enforce valid chars for sip version

The `is_version_char` function incorrectly allowed characters that are not
part of the valid SIP version "SIP/2.0".

For instance, 'HTTP/1.1' was mistakenly accepted as a valid SIP version,
although it's not.

This commit fixes the issue by updating the condition to strictly
check for the correct version string.
rust/src/sip/parser.rs