From dc3b9b75f608baddb602e6d55277ed6a55fe4d2f Mon Sep 17 00:00:00 2001 From: Pablo Neira Ayuso Date: Fri, 22 Jun 2012 16:40:24 +0200 Subject: src: add ULOGD_DTYPE_SUM for nfacct-based accounting This new type will be used in flow-up patch to support XML output. Signed-off-by: Pablo Neira Ayuso --- include/ulogd/ulogd.h | 3 ++- input/sum/ulogd_inpflow_NFACCT.c | 2 +- output/ulogd_output_GPRINT.c | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/include/ulogd/ulogd.h b/include/ulogd/ulogd.h index 89b757a..88de3ca 100644 --- a/include/ulogd/ulogd.h +++ b/include/ulogd/ulogd.h @@ -80,7 +80,8 @@ enum ulogd_dtype { ULOGD_DTYPE_RAW = 0x0002, /* raw packet data */ ULOGD_DTYPE_PACKET = 0x0004, /* packet metadata */ ULOGD_DTYPE_FLOW = 0x0008, /* flow metadata */ - ULOGD_DTYPE_SINK = 0x0010, /* sink of data, no output keys */ + ULOGD_DTYPE_SUM = 0x0010, /* sum metadata */ + ULOGD_DTYPE_SINK = 0x0020, /* sink of data, no output keys */ }; /* structure describing an input / output parameter of a plugin */ diff --git a/input/sum/ulogd_inpflow_NFACCT.c b/input/sum/ulogd_inpflow_NFACCT.c index 152cd48..751c567 100644 --- a/input/sum/ulogd_inpflow_NFACCT.c +++ b/input/sum/ulogd_inpflow_NFACCT.c @@ -245,7 +245,7 @@ static struct ulogd_plugin nfacct_plugin = { .output = { .keys = nfacct_okeys, .num_keys = ARRAY_SIZE(nfacct_okeys), - .type = ULOGD_DTYPE_FLOW, + .type = ULOGD_DTYPE_SUM, }, .config_kset = &nfacct_kset, .interp = NULL, diff --git a/output/ulogd_output_GPRINT.c b/output/ulogd_output_GPRINT.c index 759a0ca..6d2a629 100644 --- a/output/ulogd_output_GPRINT.c +++ b/output/ulogd_output_GPRINT.c @@ -248,7 +248,7 @@ static int gprint_fini(struct ulogd_pluginstance *pi) static struct ulogd_plugin gprint_plugin = { .name = "GPRINT", .input = { - .type = ULOGD_DTYPE_PACKET | ULOGD_DTYPE_FLOW, + .type = ULOGD_DTYPE_PACKET | ULOGD_DTYPE_FLOW | ULOGD_DTYPE_SUM, }, .output = { .type = ULOGD_DTYPE_SINK, -- cgit v1.2.3