suricata_SOURCES = \
alert-debuglog.c alert-debuglog.h \
alert-fastlog.c alert-fastlog.h \
-alert-json.c alert-json.h \
alert-pcapinfo.c alert-pcapinfo.h \
alert-prelude.c alert-prelude.h \
alert-syslog.c alert-syslog.h \
output-tx.c output-tx.h \
output-dnslog.c output-dnslog.h \
output-httplog.c output-httplog.h \
+output-json.c output-json.h \
output-tlslog.c output-tlslog.h \
packet-queue.c packet-queue.h \
pkt-var.c pkt-var.h \
#include "util-logopenfile.h"
#include "util-time.h"
-#include "alert-json.h"
+#include "output-json.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
AlertJsonThread *aft = (AlertJsonThread *)data;
- /* no flow, no htp state */
- if (p->flow == NULL) {
- SCLogDebug("no flow");
- SCReturnInt(TM_ECODE_OK);
- }
-
/* check if we have DNS state or not */
FLOWLOCK_WRLOCK(p->flow); /* WRITE lock before we updated flow logged id */
uint16_t proto = AppLayerGetProtoFromPacket(p);
SCReturnInt(TM_ECODE_OK);
}
+#if 0
int OutputDnsNeedsLog(Packet *p)
{
SCEnter();
SCReturnInt(1);
}
+#endif
TmEcode OutputDnsLog(ThreadVars *tv, Packet *p, void *data, PacketQueue *pq, PacketQueue *postpq)
{
SCEnter();
+ /* no flow, no htp state */
+ if (p->flow == NULL) {
+ SCReturnInt(TM_ECODE_OK);
+ }
+
+ if (!(PKT_IS_UDP(p)) && !(PKT_IS_TCP(p))) {
+ SCReturnInt(TM_ECODE_OK);
+ }
+
DnsJsonIPWrapper(tv, p, data, pq, postpq, AF_INET);
SCReturnInt(TM_ECODE_OK);
#include "util-proto-name.h"
#include "util-logopenfile.h"
#include "util-time.h"
-#include "alert-json.h"
+#include "output-json.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
#include "util-buffer.h"
#include "util-logopenfile.h"
-#include "alert-json.h"
+#include "output-json.h"
#ifndef HAVE_LIBJANSSON
}
if (outputFlags & OUTPUT_DNS) {
- if (OutputDnsNeedsLog(p)) {
- OutputDnsLog(tv, p, data, pq, postpq);
- }
+ OutputDnsLog(tv, p, data, pq, postpq);
}
if (outputFlags & OUTPUT_HTTP) {
#endif /* HAVE_LIBJANSSON */
#endif /* __ALERT_JSON_H__ */
-
#include "util-logopenfile.h"
#include "util-crypt.h"
-#include "alert-json.h"
+#include "output-json.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
#include "alert-prelude.h"
#include "alert-syslog.h"
#include "alert-pcapinfo.h"
-#include "alert-json.h"
#include "log-droplog.h"
#include "log-httplog.h"
#include "log-file.h"
#include "log-filestore.h"
+#include "output-json.h"
#include "output-dnslog.h"
#include "output-httplog.h"