Actions
Task #7703
openlua: add detection support to the suricata.file lua lib
Description
The Lua file API only supports logging at this time. Detect support should be added.
Updated by Jason Ish 8 months ago
- Related to Task #7491: lua: turn file into lua lib added
Updated by Victor Julien 17 days ago ยท Edited
One complexity is that depending on how a rule is constructed, we might get called with a single file (e.g. file.name; lua: ...). In other cases, we might get no file pointer (e.g. http.response_body; lua:...). In this case we'd have to support a way to get an array of files and then somehow select one for use.
E.g. something like
local files = filelib.get_files()
for i = 1,#files,1
do
local file = filelib.get_file_from_idx(i)
... regular file methods ...
end
Actions