X-Git-Url: http://ftp.carnet.hr/carnet-debian/scm?p=ossec-hids.git;a=blobdiff_plain;f=src%2Futil%2Fverify-agent-conf.c;fp=src%2Futil%2Fverify-agent-conf.c;h=ee684d0f8c790a1bc18094931afe59dd26e13e23;hp=0000000000000000000000000000000000000000;hb=301048b51990573e58a30dc4a5bb4ec285cad554;hpb=914feba5d54f979cd5d7e69c349c3d01f630042a diff --git a/src/util/verify-agent-conf.c b/src/util/verify-agent-conf.c new file mode 100755 index 0000000..ee684d0 --- /dev/null +++ b/src/util/verify-agent-conf.c @@ -0,0 +1,50 @@ +/* @(#) $Id$ */ + +/* Copyright (C) 2010 Trend Micro Inc. + * All right reserved. + * + * This program is a free software; you can redistribute it + * and/or modify it under the terms of the GNU General Public + * License (version 2) as published by the FSF - Free Software + * Foundation + */ + + +#include "shared.h" +#include "config/localfile-config.h" +#include "config/config.h" +#include "logcollector/logcollector.h" + + +#undef ARGV0 +#define ARGV0 "verify-agent-conf" + + + +/* main: v0.3: 2005/04/04 */ +int main(int argc, char **argv) +{ + int modules = 0; + logreader_config log_config; + + + /* Setting the name */ + OS_SetName(ARGV0); + + + modules|= CLOCALFILE; + modules|= CAGENT_CONFIG; + log_config.config = NULL; + if(ReadConfig(modules, AGENTCONFIG, &log_config, NULL) < 0) + { + return(OS_INVALID); + } + + logff = log_config.config; + + return(0); + + +} + +/* EOF */