Commit Graph

9 Commits (79a3c6c7b1f1b2a99191ff8df4deb43f12c9c547)

Author SHA1 Message Date
Nicolas Thill e95e6ccded lua: add an SCPacketTimestamp function
The SCPacketTimestamp function returns packet timestamps as 2 real
numbers (seconds & microseconds).

Example:

  local sec, usec = SCPacketTimestamp()

Signed-off-by: Nicolas Thill <ntl@p1sec.com>
9 years ago
Duarte Silva 89eb935f73 file-hashing: added support for SHA-256 file hashing 9 years ago
Duarte Silva a6d928e269 file-hashing: added support for SHA-1 file hashing 9 years ago
Jason Ish 8865009fca lua: remove flow locking from the lua layer 9 years ago
Victor Julien e43ce0a9ec file: switch to streaming buffer API
Make the file storage use the streaming buffer API.

As the individual file chunks were not needed by themselves, this
approach uses a chunkless implementation.
9 years ago
Victor Julien 554080cced lua: print lua script func/line/file in SCLog* funcs
Instead of printing the func/line/file of the C code SCLog* wrappers,
print them from inside the lua script. They are not always available.
9 years ago
Victor Julien 16941468ce lua: in streaming api, indicate open/close
The SCStreamingBuffer call now also returns two booleans:
    data, data_open, data_close = SCStreamingBuffer()

The first indicates this is the first data of this type for this
TCP session or HTTP transaction.

The second indicates this is the last data.

Ticket #1317.
11 years ago
Eric Leblond 74ffa2b264 lua: move function to common utils
LuaStateNeedProto function can be used for any protocol so let's
move it out of the http file.
11 years ago
Victor Julien a114787150 lua: move lua output code to generic lua file
So that other Lua scripts (detect) can also start using it.
11 years ago