1 /* @(#) $Id: config.c,v 1.32 2009/11/04 15:18:59 dcid Exp $ */
3 /* Copyright (C) 2009 Trend Micro Inc.
6 * This program is a free software; you can redistribute it
7 * and/or modify it under the terms of the GNU General Public
8 * License (version 3) as published by the FSF - Free Software
11 * License details at the LICENSE file included with OSSEC or
12 * online at: http://www.ossec.net/en/licensing.html
16 /* Functions to handle the configuration files
22 #include "os_xml/os_xml.h"
23 #include "os_regex/os_regex.h"
25 #include "analysisd.h"
29 /* GlobalConf vv0.2: 2005/03/03
30 * v0.2: Changing to support the new OS_XML
32 int GlobalConf(char * cfgfile)
45 Config.memorysize = 1024;
46 Config.mailnotify = -1;
47 Config.keeplogdate = 0;
48 Config.syscheck_alert_new = 0;
49 Config.syscheck_auto_ignore = 1;
52 Config.syscheck_ignore = NULL;
53 Config.white_list = NULL;
54 Config.hostname_white_list = NULL;
56 /* Default actions -- only log above level 1 */
57 Config.mailbylevel = 7;
58 Config.logbylevel = 1;
60 Config.includes = NULL;
68 if(ReadConfig(modules, cfgfile, &Config, NULL)< 0)
73 /* Minimum memory size */
74 if(Config.memorysize < 64)
75 Config.memorysize = 64;