Skip to content

Commit

Permalink
WIP remove old lua payload/packet stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
victorjulien committed Jan 21, 2025
1 parent 48a5783 commit 03f7f04
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions src/detect-lua.c
Original file line number Diff line number Diff line change
Expand Up @@ -328,16 +328,6 @@ static int DetectLuaMatch (DetectEngineThreadCtx *det_ctx,
lua_getglobal(tlua->luastate, "match");
lua_newtable(tlua->luastate); /* stack at -1 */

if ((tlua->flags & FLAG_DATATYPE_PAYLOAD) && p->payload_len) {
lua_pushliteral(tlua->luastate, "payload"); /* stack at -2 */
LuaPushStringBuffer (tlua->luastate, (const uint8_t *)p->payload, (size_t)p->payload_len); /* stack at -3 */
lua_settable(tlua->luastate, -3);
}
if ((tlua->flags & FLAG_DATATYPE_PACKET) && GET_PKT_LEN(p)) {
lua_pushliteral(tlua->luastate, "packet"); /* stack at -2 */
LuaPushStringBuffer (tlua->luastate, (const uint8_t *)GET_PKT_DATA(p), (size_t)GET_PKT_LEN(p)); /* stack at -3 */
lua_settable(tlua->luastate, -3);
}
SCReturnInt(DetectLuaRunMatch(det_ctx, lua, tlua));
}

Expand Down

0 comments on commit 03f7f04

Please sign in to comment.