Imported Upstream version 2.7
[ossec-hids.git] / src / config / config.h
1 /* @(#) $Id: ./src/config/config.h, 2011/09/08 dcid Exp $
2  */
3
4 /* Copyright (C) 2009 Trend Micro Inc.
5  * All rights reserved.
6  *
7  * This program is a free software; you can redistribute it
8  * and/or modify it under the terms of the GNU General Public
9  * License (version 2) as published by the FSF - Free Software
10  * Foundation
11  *
12  * License details at the LICENSE file included with OSSEC or
13  * online at: http://www.ossec.net/en/licensing.html
14  */
15
16
17
18 #ifndef _HCONFIG__H
19 #define _HCONFIG__H
20
21 #define CGLOBAL       0000001
22 #define CRULES        0000002
23 #define CSYSCHECK     0000004
24 #define CROOTCHECK    0000010
25 #define CALERTS       0000020
26 #define CLOCALFILE    0000040
27 #define CREMOTE       0000100
28 #define CCLIENT       0000200
29 #define CMAIL         0000400
30 #define CAR           0001000
31 #define CDBD          0002000
32 #define CSYSLOGD      0004000
33 #define CAGENTLESS    0020000
34 #define CREPORTS      0040000
35
36 #define CAGENT_CONFIG 0010000
37
38 #include "os_xml/os_xml.h"
39
40
41 /* Main function to read the config */
42 int ReadConfig(int modules, char *cfgfile, void *d1, void *d2);
43
44 int Read_Global(XML_NODE node, void *d1, void *d2);
45 int Read_GlobalSK(XML_NODE node, void *configp, void *mailp);
46 int Read_Rules(XML_NODE node, void *d1, void *d2);
47 int Read_Syscheck(XML_NODE node, void *d1, void *d2);
48 int Read_Rootcheck(XML_NODE node, void *d1, void *d2);
49 int Read_Alerts(XML_NODE node, void *d1, void *d2);
50 int Read_EmailAlerts(XML_NODE node, void *d1, void *d2);
51 int Read_DB(XML_NODE node, void *config1, void *config2);
52 int Read_CSyslog(XML_NODE node, void *config1, void *config2);
53 int Read_CAgentless(XML_NODE node, void *config1, void *config2);
54 int Read_Localfile(XML_NODE node, void *d1, void *d2);
55 int Read_Remote(XML_NODE node, void *d1, void *d2);
56 int Read_Client(XML_NODE node, void *d1, void *d2);
57 int ReadActiveResponses(XML_NODE node, void *d1, void *d2);
58 int ReadActiveCommands(XML_NODE node, void *d1, void *d2);
59 int Read_CReports(XML_NODE node, void *config1, void *config2);
60 void AssignIgnore_Global(char **ignores, void *configp);
61
62
63 /* General config, for passing blobs of data. */
64 typedef struct _GeneralConfig
65 {
66     void *data;
67 }GeneralConfig;
68
69
70 #endif