ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/hopm/trunk/src/config.h
Revision: 5879
Committed: Sat May 2 14:02:17 2015 UTC (11 years, 2 months ago) by michael
Content type: text/x-chdr
File size: 2725 byte(s)
Log Message:
- config.h: made BlacklistReplyConf::number unsigned

File Contents

# User Rev Content
1 michael 5351 /*
2     * Copyright (c) 2002 Erik Fears
3     * Copyright (c) 2014-2015 ircd-hybrid development team
4     *
5     * This program is free software; you can redistribute it and/or modify
6     * it under the terms of the GNU General Public License as published by
7     * the Free Software Foundation; either version 2 of the License, or
8     * (at your option) any later version.
9     *
10     * This program is distributed in the hope that it will be useful,
11     * but WITHOUT ANY WARRANTY; without even the implied warranty of
12     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13     * GNU General Public License for more details.
14     *
15     * You should have received a copy of the GNU General Public License
16     * along with this program; if not, write to the Free Software
17     * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
18     * USA
19     */
20    
21 michael 5052 #ifndef CONFIG_H
22     #define CONFIG_H
23    
24     #include <stdio.h>
25 michael 5198 #include <time.h>
26 michael 5052 #include "list.h"
27     #include "libopm/src/opm_types.h"
28    
29     extern char linebuf[512];
30     extern int linenum;
31    
32     extern void yyerror(const char *);
33     extern void config_load(const char *);
34    
35    
36     struct IRCConf
37     {
38 michael 5120 char *nick;
39     char *username;
40     char *realname;
41     char *server;
42     int port;
43 michael 5198 time_t readtimeout;
44 michael 5120 char *password;
45     char *vhost;
46     char *nickserv;
47     char *oper;
48     char *mode;
49     char *away;
50     char *connregex;
51     char *kline;
52     list_t *channels; /* List of ChannelConf */
53     list_t *performs; /* List of char * */
54 michael 5405 list_t *notices; /* List of char * */
55 michael 5052 };
56    
57     struct ChannelConf
58     {
59 michael 5120 char *name;
60     char *key;
61     char *invite;
62 michael 5052 };
63    
64     struct OptionsConf
65     {
66 michael 5120 int negcache;
67 michael 5332 time_t negcache_rebuild;
68 michael 5120 unsigned int dns_fdlimit;
69     char *pidfile;
70     char *scanlog;
71 michael 5052 };
72    
73     struct UserConf
74     {
75 michael 5120 list_t *masks; /* List of char * */
76     list_t *scanners; /* List of char * */
77 michael 5052 };
78    
79     struct ScannerConf
80     {
81 michael 5120 char *name;
82     list_t *protocols;
83     char *vhost;
84     int fd;
85     char *target_ip;
86     int target_port;
87     int timeout;
88     int max_read;
89     list_t *target_string;
90     int target_string_created;
91 michael 5052 };
92    
93     struct ProtocolConf
94     {
95 michael 5120 int type;
96     unsigned int port;
97 michael 5052 };
98    
99     struct OpmConf
100     {
101 michael 5120 list_t *blacklists;
102     char *dnsbl_from;
103     char *dnsbl_to;
104     char *sendmail;
105 michael 5052 };
106    
107 michael 5120 enum BlacklistType
108     {
109 michael 5052 A_BITMASK = 1,
110     A_REPLY
111     };
112    
113     struct BlacklistConf
114     {
115 michael 5120 char *name;
116     char *kline;
117     enum BlacklistType type;
118     int ban_unknown;
119     list_t *reply;
120     unsigned int stats_recv;
121 michael 5052 };
122    
123     struct BlacklistReplyConf
124     {
125 michael 5879 unsigned char number;
126 michael 5120 char *type;
127 michael 5052 };
128    
129     struct ExemptConf
130     {
131 michael 5120 list_t *masks;
132 michael 5052 };
133    
134    
135     /* Extern to actual config data declared in config.c */
136     extern struct IRCConf *IRCItem;
137     extern struct OptionsConf *OptionsItem;
138     extern struct OpmConf *OpmItem;
139     extern struct ExemptConf *ExemptItem;
140     extern list_t *UserItemList;
141     extern list_t *ScannerItemList;
142    
143     #endif /* CONFIG_H */

Properties

Name Value
svn:eol-style native
svn:keywords Id