From ec7d446f16fefdb609b0f79478eeed4099a7c813 Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Fri, 2 May 2014 08:25:22 +0200 Subject: [PATCH] flow-log: log pkts, bytes Only in DEBUG currently. --- src/output-json-flow.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/output-json-flow.c b/src/output-json-flow.c index 495f784921..7416c5f2ef 100644 --- a/src/output-json-flow.c +++ b/src/output-json-flow.c @@ -181,6 +181,18 @@ static void JsonFlowLogJSON(JsonFlowLogThread *aft, json_t *js, Flow *f) json_object_set_new(hjs, "app_proto", json_string(AppProtoToString(f->alproto))); + /* debug until we move this out of the debug wrapper in the flow code */ +#ifdef DEBUG + json_object_set_new(hjs, "pkts_toserver", + json_integer(f->todstpktcnt)); + json_object_set_new(hjs, "pkts_toclient", + json_integer(f->tosrcpktcnt)); + json_object_set_new(hjs, "bytes", + json_integer(f->bytecnt)); + + +#endif + json_object_set_new(js, "flow", hjs); }