jansson: include in suricata-common.h

pull/1867/head
Victor Julien 10 years ago
parent 8c0e575063
commit c446abeb47

@ -141,9 +141,8 @@ void StatsThreadCleanup(struct ThreadVars_ *);
} while (0)
#ifdef BUILD_UNIX_SOCKET
#include <jansson.h>
TmEcode StatsOutputCounterSocket(json_t *cmd,
json_t *answer, void *data);
json_t *answer, void *data);
#endif
#endif /* __COUNTERS_H__ */

@ -69,7 +69,6 @@
#define MODULE_NAME "JsonAlertLog"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
#define LOG_JSON_PAYLOAD 1
#define LOG_JSON_PACKET 2

@ -29,7 +29,6 @@
void TmModuleJsonAlertLogRegister (void);
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
void AlertJsonHeader(const Packet *p, const PacketAlert *pa, json_t *js);
#endif /* HAVE_LIBJANSSON */

@ -51,7 +51,6 @@
#include "output-json.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
/* we can do query logging as well, but it's disabled for now as the
* TX id handling doesn't expect it */

@ -59,7 +59,6 @@
#define MODULE_NAME "JsonDropLog"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
#define LOG_DROP_ALERTS 1

@ -54,7 +54,6 @@
#include "output-json-email-common.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
#define LOG_EMAIL_DEFAULT 0
#define LOG_EMAIL_EXTENDED (1<<0)

@ -65,7 +65,6 @@
#include "stream-tcp-reassemble.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
typedef struct OutputFileCtx_ {
LogFileCtx *file_ctx;

@ -49,7 +49,6 @@
#include "stream-tcp-private.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
typedef struct LogJsonFileCtx_ {
LogFileCtx *file_ctx;

@ -50,7 +50,6 @@
#include "output-json.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
typedef struct LogHttpFileCtx_ {
LogFileCtx *file_ctx;

@ -27,7 +27,6 @@
void TmModuleJsonHttpLogRegister (void);
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
void JsonHttpLogJSONBasic(json_t *js, htp_tx_t *tx);
void JsonHttpLogJSONExtended(json_t *js, htp_tx_t *tx);
json_t *JsonHttpAddMetadata(const Flow *f, uint64_t tx_id);

@ -49,7 +49,6 @@
#include "stream-tcp-private.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
typedef struct LogJsonFileCtx_ {
LogFileCtx *file_ctx;

@ -52,7 +52,6 @@
#include "output-json-email-common.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
static json_t *JsonSmtpDataLogger(const Flow *f, void *state, void *vtx, uint64_t tx_id)
{

@ -26,7 +26,6 @@
void TmModuleJsonSmtpLogRegister (void);
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
json_t *JsonSMTPAddMetadata(const Flow *f, uint64_t tx_id);
#endif

@ -50,7 +50,6 @@
#include "output-json.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
#define MODULE_NAME "LogSshLog"

@ -28,7 +28,6 @@ void TmModuleJsonSshLogRegister (void);
#ifdef HAVE_LIBJANSSON
#include "app-layer-ssh.h"
#include <jansson.h>
void JsonSshLogJSON(json_t *js, SshState *tx);
#endif

@ -49,7 +49,6 @@
#define MODULE_NAME "JsonStatsLog"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
#define JSON_STATS_TOTALS (1<<0)
#define JSON_STATS_THREADS (1<<1)

@ -39,7 +39,6 @@
#include "app-layer-template.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
typedef struct LogTemplateFileCtx_ {
LogFileCtx *file_ctx;

@ -50,7 +50,6 @@
#include "output-json.h"
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
SC_ATOMIC_DECLARE(unsigned int, cert_id);

@ -28,7 +28,6 @@ void TmModuleJsonTlsLogRegister (void);
#ifdef HAVE_LIBJANSSON
#include "app-layer-ssl.h"
#include <jansson.h>
void JsonTlsLogJSONBasic(json_t *js, SSLState *ssl_state);
void JsonTlsLogJSONExtended(json_t *js, SSLState *ssl_state);

@ -109,8 +109,6 @@ void OutputJsonRegisterTests (void)
#else /* implied we do have JSON support */
#include <jansson.h>
#define DEFAULT_LOG_FILENAME "eve.json"
#define DEFAULT_ALERT_SYSLOG_FACILITY_STR "local0"
#define DEFAULT_ALERT_SYSLOG_FACILITY LOG_LOCAL0

@ -24,15 +24,14 @@
#ifndef __OUTPUT_JSON_H__
#define __OUTPUT_JSON_H__
void TmModuleOutputJsonRegister (void);
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
#include "suricata-common.h"
#include "util-buffer.h"
#include "util-logopenfile.h"
void TmModuleOutputJsonRegister (void);
#ifdef HAVE_LIBJANSSON
void CreateJSONFlowId(json_t *js, const Flow *f);
void JsonTcpFlags(uint8_t flags, json_t *js);
json_t *CreateJSONHeader(Packet *p, int direction_sensative, char *event_type);

@ -210,6 +210,10 @@
#endif
#endif /* !__CYGWIN__ */
#ifdef HAVE_LIBJANSSON
#include <jansson.h>
#endif
#if CPPCHECK==1
#define BUG_ON(x) if (((x))) exit(1)
#else

Loading…
Cancel
Save