Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -956,7 +956,7 @@ syscheck_update: util/syscheck_update.o addagent/validate.o ${ossec_libs} ${ZLIB
clear_stats: util/clear_stats.o ${ossec_libs} ${ZLIB_LIB}
${OSSEC_CCBIN} ${OSSEC_CFLAGS} ${ZLIB_INCLUDE} $^ ${OSSEC_LDFLAGS} -o $@

list_agents: util/list_agents.o ${ossec_libs} ${ZLIB_LIB}
list_agents: util/list_agents.o ${ossec_libs} ${ZLIB_LIB} ${JSON_LIB}
${OSSEC_CCBIN} ${OSSEC_CFLAGS} ${ZLIB_INCLUDE} $^ ${OSSEC_LDFLAGS} -o $@

verify-agent-conf: util/verify-agent-conf.o ${ossec_libs} ${ZLIB_LIB}
Expand Down Expand Up @@ -1020,7 +1020,7 @@ monitor_o := $(monitor_c:.c=.o)
monitord/%.o: monitord/%.c ${ZLIB_LIB}
${OSSEC_CC} ${OSSEC_CFLAGS} -DARGV0=\"ossec-monitord\" -c $< -o $@

ossec-monitord: ${monitor_o} ${ossec_libs} ${ZLIB_LIB}
ossec-monitord: ${monitor_o} ${ossec_libs} ${ZLIB_LIB} ${JSON_LIB}
${OSSEC_CCBIN} ${OSSEC_CFLAGS} ${ZLIB_INCLUDE} $^ ${OSSEC_LDFLAGS} -o $@


Expand Down Expand Up @@ -1194,16 +1194,16 @@ test_os_zlib: tests/test_os_zlib.o ${ZLIB_LIB}
test_os_xml: tests/test_os_xml.o ${os_xml_o}
${OSSEC_CCBIN} ${OSSEC_CFLAGS} $^ ${OSSEC_LDFLAGS} -o $@

test_os_regex: tests/test_os_regex.c ${os_regex_o}
test_os_regex: tests/test_os_regex.c ${os_regex_o}
${OSSEC_CCBIN} ${OSSEC_CFLAGS} $^ ${OSSEC_LDFLAGS} -o $@

test_os_crypto: tests/test_os_crypto.c ${crypto_o} ${shared_o} ${os_xml_o} ${os_net_o} ${os_regex_o} ${ZLIB_LIB}
test_os_crypto: tests/test_os_crypto.c ${crypto_o} ${shared_o} ${os_xml_o} ${os_net_o} ${os_regex_o} ${ZLIB_LIB} ${JSON_LIB}
${OSSEC_CCBIN} ${OSSEC_CFLAGS} $^ ${OSSEC_LDFLAGS} -o $@

#test_os_net: tests/test_os_net.c ${os_net_o} ${shared_o} ${os_regex_o} ${os_xml_o}
# ${OSSEC_CCBIN} ${OSSEC_CFLAGS} $^ ${OSSEC_LDFLAGS} -o $@

test_shared: tests/test_shared.c ${shared_o} ${os_xml_o} ${os_net_o} ${os_regex_o}
test_shared: tests/test_shared.c ${shared_o} ${os_xml_o} ${os_net_o} ${os_regex_o} ${JSON_LIB}
${OSSEC_CCBIN} ${OSSEC_CFLAGS} $^ ${OSSEC_LDFLAGS} -o $@

test_valgrind: build_tests
Expand Down
8 changes: 6 additions & 2 deletions src/headers/read-agents.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@
#ifndef __CRAGENT_H
#define __CRAGENT_H

#include <external/cJSON/cJSON.h>


/* Unique key for each agent */
typedef struct _agent_info {
char *last_keepalive;
Expand All @@ -23,11 +26,12 @@ typedef struct _agent_info {

/* Print syscheck db (of modified files) */
int print_syscheck(const char *sk_name, const char *sk_ip, const char *fname, int print_registry,
int all_files, int csv_output, int update_counter);
int all_files, int csv_output, cJSON *json_output, int update_counter);

/* Print rootcheck db */
int print_rootcheck(const char *sk_name, const char *sk_ip, const char *fname, int resolved,
int csv_output, int show_last);
int csv_output, cJSON *json_output, int show_last);


/* Delete syscheck db */
int delete_syscheck(const char *sk_name, const char *sk_ip, int full_delete) __attribute__((nonnull));
Expand Down
Loading