]> git.ipfire.org Git - thirdparty/suricata.git/commit
lua: convert flowvar functions to lib 13097/head
authorJason Ish <jason.ish@oisf.net>
Thu, 24 Apr 2025 18:11:28 +0000 (12:11 -0600)
committerJason Ish <jason.ish@oisf.net>
Mon, 28 Apr 2025 00:58:47 +0000 (18:58 -0600)
commit35b03b4077c908251396f74fe0fb50e881b44e8e
tree73bf51ddac10afd291a5fd6b7465dc2aff5634fa
parentdaabab738174b7055f5d59ea4b7d158daa4f450c
lua: convert flowvar functions to lib

New Lua lib, "suricata.flowvar" for working with flowvars from Lua.

Replaces functions:
- SCFlowvarGet (and ScFlowvarGet)
- SCFlowvarSet (and SCFlowvarSet)

Of note, the DetectLuaData has been made available to the init and
thread_init methods, instead of just the match. This is due to an
issue that if a flow variable is not registered in init, it will not
be logged, registering in thread_init is too late.

Ticket: #7486
doc/userguide/lua/libs/flowvar.rst [new file with mode: 0644]
doc/userguide/lua/libs/index.rst
doc/userguide/lua/lua-functions.rst
src/Makefile.am
src/detect-lua-extensions.c
src/detect-lua-extensions.h
src/detect-lua.c
src/util-lua-builtins.c
src/util-lua-flowvarlib.c [new file with mode: 0644]
src/util-lua-flowvarlib.h [new file with mode: 0644]