snort3: fix issue caused by ucode semantics change
A recent change in the ucode interpeter caused a failure when using
the 'in' operator.
be767ae197
Reported in a forum post by @graysky2.
https://forum.openwrt.org/t/194218/28
Signed-off-by: Eric Fahlgren <ericfahlgren@gmail.com>
This commit is contained in:
parent
50810923da
commit
4ce2d741c6
|
@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
|
|||
|
||||
PKG_NAME:=snort3
|
||||
PKG_VERSION:=3.1.82.0
|
||||
PKG_RELEASE:=2
|
||||
PKG_RELEASE:=3
|
||||
|
||||
PKG_SOURCE:=$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://github.com/snort3/snort3/archive/refs/tags/
|
||||
|
|
|
@ -76,6 +76,10 @@ function config_item(type, values, def) {
|
|||
wrn(`Invalid item type '${type}', must be one of "enum", "range", "path" or "str".`);
|
||||
return;
|
||||
}
|
||||
if (type == "enum") {
|
||||
// Convert values to strings, so 'in' works in 'contains'.
|
||||
values = map(values, function(i) { return "" + i; });
|
||||
}
|
||||
if (type == "range" && (length(values) != 2 || values[0] > values[1])) {
|
||||
wrn(`A 'range' type item must have exactly 2 values in ascending order.`);
|
||||
return;
|
||||
|
|
Loading…
Reference in New Issue