Lua scripting can be used in two components of Suricata. The first is in output an the second one in rules in the detection engine.
Both features are using a list of functions to access to data extracted by Suricata. You can get the list of functions in the lua-functions
page.
Lua can be used to write arbitrary output. See lua-output
for more information.
Lua script can be used as a filter condition in signatures. See lua-scripting
for more information.