]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
config: common definitions
authorVictor Julien <victor@inliniac.net>
Wed, 18 Mar 2020 19:50:47 +0000 (20:50 +0100)
committerVictor Julien <victor@inliniac.net>
Sat, 11 Jul 2020 06:37:40 +0000 (08:37 +0200)
src/Makefile.am
src/util-config.h [new file with mode: 0644]

index 839adc31747dd9e321a8c79d89bea18467a5e8b3..876925423b32eb60d0f10d19165b058c850b8c78 100755 (executable)
@@ -441,6 +441,7 @@ util-byte.c util-byte.h \
 util-checksum.c util-checksum.h \
 util-cidr.c util-cidr.h \
 util-classification-config.c util-classification-config.h \
+util-config.h \
 util-conf.c util-conf.h \
 util-coredump-config.c util-coredump-config.h \
 util-cpu.c util-cpu.h \
diff --git a/src/util-config.h b/src/util-config.h
new file mode 100644 (file)
index 0000000..e0a5bdb
--- /dev/null
@@ -0,0 +1,53 @@
+/* Copyright (C) 2020 Open Information Security Foundation
+ *
+ * You can copy, redistribute or modify this Program under the terms of
+ * the GNU General Public License version 2 as published by the Free
+ * Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * version 2 along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301, USA.
+ */
+
+/**
+ * \file
+ *
+ * \author Victor Julien <victor@inliniac.net>
+ */
+
+#ifndef __UTIL_CONFIG_H__
+#define __UTIL_CONFIG_H__
+
+enum ConfigAction {
+    CONFIG_ACTION_UNSET = 0,
+    CONFIG_ACTION_SET = 1,
+};
+
+enum ConfigSubsys {
+    CONFIG_SUBSYS_LOGGING = 0,
+};
+
+enum ConfigType {
+    CONFIG_TYPE_TX = 0,     /* transaction logging */
+    CONFIG_TYPE_FLOW,       /* flow logging */
+    CONFIG_TYPE_ALERT,      /* alert logging */
+    CONFIG_TYPE_ANOMALY,    /* anomaly logging */
+    CONFIG_TYPE_FILE,       /* file logging */
+    CONFIG_TYPE_PCAP,       /* pcap logging */
+    CONFIG_TYPE_DROP,       /* drop logging */
+#define CONFIG_TYPE_DEFAULT CONFIG_TYPE_TX
+};
+
+enum ConfigScope {
+    CONFIG_SCOPE_TX = 0,    /* per transaction */
+    CONFIG_SCOPE_FLOW,      /* per flow */
+#define CONFIG_SCOPE_DEFAULT CONFIG_SCOPE_TX
+};
+
+#endif