Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 355 lines (330 sloc) 8.318 kb
07aaac6 Initial revision
dm authored
1 /*
2 * iroffer by David Johnson (PMG)
3 * Copyright (C) 1998-2005 David Johnson
4 *
5 * By using this file, you agree to the terms and conditions set
6 * forth in the GNU General Public License. More information is
8c47b72 - spaces and LICENSE
dm authored
7 * available in the LICENSE file.
07aaac6 Initial revision
dm authored
8 *
9 * If you received this file without documentation, it can be
10 * downloaded from http://iroffer.org/
11 *
c62ead9 sync with iroffer1.4.b03 (from PMG)
dm authored
12 * @(#) iroffer_globals.h 1.121@(#)
13 * pmg@wellington.i202.centerclick.org|src/iroffer_globals.h|20051123201144|11503
07aaac6 Initial revision
dm authored
14 *
15 */
16
17 #if !defined _IROFFER_GLOBALS
18 #define _IROFFER_GLOBALS
19
7b8475e - create dinoex_globals.h
dm authored
20 #include "dinoex_globals.h"
07aaac6 Initial revision
dm authored
21
22 typedef struct
23 {
24 /* config */
25 struct
26 {
2ff5b99 - use ir_int64
cvs authored
27 ir_int64 limit;
28 ir_int64 used;
07aaac6 Initial revision
dm authored
29 time_t ends;
30 } transferlimits[NUMBER_TRANSFERLIMITS];
4e6d055 - convert to unsigned
cvs authored
31 gnetwork_t networks[MAX_NETWORKS];
07aaac6 Initial revision
dm authored
32
4e6d055 - convert to unsigned
cvs authored
33 off_t uploadmaxsize;
34 off_t uploadminspace;
35 off_t disk_quota;
36 time_t configtime[MAXCONFIG];
37 time_t logrotate;
07aaac6 Initial revision
dm authored
38 irlist_t downloadhost;
ecdffe6 nodownloadhost
dm authored
39 irlist_t nodownloadhost;
f240379 - http_allow, http_deny
dm authored
40 irlist_t http_allow;
41 irlist_t http_deny;
bbba185 - xdcc_deny, xdcc_allow
dm authored
42 irlist_t xdcc_allow;
43 irlist_t xdcc_deny;
07aaac6 Initial revision
dm authored
44 irlist_t adminhost;
7654c49 - half admin
dm authored
45 irlist_t hadminhost;
c7b7b29 - mutiple filedir
dm authored
46 irlist_t filedir;
07aaac6 Initial revision
dm authored
47 irlist_t uploadhost;
ba41685 - admin command: ACCEPTU
dm authored
48 irlist_t tuploadhost;
0f002dc - new admin command "GET"
dm authored
49 irlist_t quploadhost;
4e6d055 - convert to unsigned
cvs authored
50 irlist_t autoignore_exclude;
a80b34d - noduplicatefiles
dm authored
51 irlist_t adddir_exclude;
67f17ec autosendpack can now be used mutiple times
dm authored
52 irlist_t autoqueue;
c761174 - autotrigger + CHTRIGGER
dm authored
53 irlist_t autotrigger;
f925e91 unlimitedhost
dm authored
54 irlist_t unlimitedhost;
cd35967 geoipcountry
dm authored
55 irlist_t geoipcountry;
3df2a5e - nogeoipcountry
dm authored
56 irlist_t nogeoipcountry;
c40b621 - geoipexcludenick
dm authored
57 irlist_t geoipexcludenick;
da37efb - geoipexcludegroup
cvs authored
58 irlist_t geoipexcludegroup;
d65504e autoadd_dir multiple
dm authored
59 irlist_t autoadd_dirs;
7f00f00 - include_subdirs
dm authored
60 irlist_t packs_delayed;
178f1f2 admin_job_file mass updates
dm authored
61 irlist_t jobs_delayed;
ebc1d3c - option "autocrc_exclude"
dm authored
62 irlist_t autocrc_exclude;
bd638d9 - option http_port
dm authored
63 irlist_t https;
aa437a5 - badip list for ipv6
dm authored
64 irlist_t http_bad_ip4;
65 irlist_t http_bad_ip6;
7854cba - http_vhost, telnet_vhost
dm authored
66 irlist_t http_vhost;
67 irlist_t telnet_vhost;
b7cb3d2 - weblist_info
dm authored
68 irlist_t weblist_info;
7078aa5 - mime_type
dm authored
69 irlist_t mime_type;
1cc1888 - autoadd_group_match
dm authored
70 irlist_t autoadd_group_match;
8abb5a6 - log_exclude_host, log_exclude_text
dm authored
71 irlist_t log_exclude_host;
72 irlist_t log_exclude_text;
716e281 - fish_exclude_nick
dm authored
73 irlist_t fish_exclude_nick;
ef87446 - group_admin
dm authored
74 irlist_t group_admin;
4e6d055 - convert to unsigned
cvs authored
75 char *configfile[MAXCONFIG];
76 char *osstring;
77 char *pidfile;
78 char *local_vhost;
79 char *logfile;
80 char *headline;
81 char *creditline;
82 char *adminpass;
83 char *hadminpass;
84 char *statefile;
85 char *xdcclistfile;
86 char *periodicmsg_nick, *periodicmsg_msg;
87 char *config_nick;
88 char *user_realname, *user_modes, *loginname;
89 char *restrictprivlistmsg;
90 char *uploaddir;
91 char *nickserv_pass;
a80b34d - noduplicatefiles
dm authored
92 char *enable_nick;
61ad917 - owner_nick
dm authored
93 char *owner_nick;
8855499 send_statefile
dm authored
94 char *admin_job_file;
95 char *autoaddann;
96 char *autoadd_group;
97 char *send_statefile;
3f9f7dc geoipdatabase
dm authored
98 char *geoipdatabase;
051a901 - respondtochannellistmsg
dm authored
99 char *respondtochannellistmsg;
4ddc268 - xdccremovefile
dm authored
100 char *xdccremovefile;
1ad7e50 - option "autoadd_sort"
dm authored
101 char *autoadd_sort;
3e5b502 - http_admin
dm authored
102 char *http_admin;
894235b - http_dir
dm authored
103 char *http_dir;
4854206 - group_seperator
dm authored
104 char *group_seperator;
f2a5295 - usenatip per network
dm authored
105 char *usenatip;
872544a - logfile_notices, logfile_messages
dm authored
106 char *logfile_notices;
107 char *logfile_messages;
f024d8d - logfile_httpd
cvs authored
108 char *logfile_httpd;
2c09992 - trashcan_dir
dm authored
109 char *trashcan_dir;
2bdaa66 - xdccxmlfile
dm authored
110 char *xdccxmlfile;
838d842 - http_date
dm authored
111 char *http_date;
abf40c8 - announce_separator
dm authored
112 char *announce_seperator;
065ef6c - admin command "NOSEND x msg"
dm authored
113 char *nosendmsg;
336d08b - privmsg_fish
dm authored
114 char *privmsg_fish;
a1c2d9e - ruby_script
dm authored
115 char *ruby_script;
100586d - new option charset
dm authored
116 char *charset;
eab825f - http_admin_dir
cvs authored
117 char *http_admin_dir;
d59dd63 - http_index
cvs authored
118 char *http_index;
e36cb8c - download_completed_msg
cvs authored
119 char *download_completed_msg;
9e7f978 - http_access_log
cvs authored
120 char *http_access_log;
cdea602 - autoadd_color
cvs authored
121 char *autoadd_color;
28861ef - http_forbidden
cvs authored
122 char *http_forbidden;
4e6d055 - convert to unsigned
cvs authored
123 float transferminspeed, transfermaxspeed;
124 unsigned char overallmaxspeeddaydays;
125 unsigned char cdummy;
126 unsigned short sdummy;
127 /* int */
128 unsigned int lowbdwth;
129 unsigned int tcprangestart;
130 unsigned int tcprangelimit;
131 unsigned int overallmaxspeed, overallmaxspeeddayspeed;
132 unsigned int maxtransfersperperson, maxqueueditemsperperson;
133 unsigned int maxidlequeuedperperson;
134 unsigned int debug;
135 unsigned int slotsmax;
136 unsigned int queuesize;
137 unsigned int idlequeuesize;
138 unsigned int punishslowusers;
139 unsigned int need_level;
140 unsigned int start_of_month;
141 unsigned int atfind;
142 unsigned int waitafterjoin;
143 unsigned int autoadd_time;
144 unsigned int restrictsend_timeout;
145 unsigned int send_statefile_minute;
146 unsigned int max_uploads;
147 unsigned int max_upspeed;
148 unsigned int max_find;
149 unsigned int restrictsend_delay;
150 unsigned int adminlevel;
151 unsigned int hadminlevel;
152 unsigned int monitor_files;
153 unsigned int autoadd_delay;
154 unsigned int http_port;
155 unsigned int telnet_port;
156 unsigned int remove_dead_users;
157 unsigned int send_listfile;
158 unsigned int fileremove_max_packs;
159 unsigned int status_time_dcc_chat;
160 unsigned int notifytime;
161 unsigned int smallfilebypass;
162 unsigned int autoignore_threshold;
163 unsigned int reconnect_delay;
164 unsigned int new_trigger;
165 /* bool */
166 unsigned int hideos;
167 unsigned int lognotices;
168 unsigned int logmessages;
169 unsigned int timestampconsole;
170 unsigned int logstats;
171 unsigned int background;
172 unsigned int xdcclistfileraw;
173 unsigned int restrictlist, restrictsend, restrictprivlist;
174 unsigned int nomd5sum;
175 unsigned int getipfromserver;
176 unsigned int noduplicatefiles;
177 unsigned int dos_text_files;
178 unsigned int no_duplicate_filenames;
179 unsigned int show_list_all;
180 unsigned int getipfromupnp;
181 unsigned int hide_list_info;
182 unsigned int xdcclist_grouponly;
183 unsigned int auto_default_group;
184 unsigned int auto_path_group;
185 unsigned int restrictprivlistmain;
186 unsigned int restrictprivlistfull;
187 unsigned int groupsincaps;
188 unsigned int ignoreuploadbandwidth;
189 unsigned int holdqueue;
190 unsigned int removelostfiles;
191 unsigned int ignoreduplicateip;
192 unsigned int hidelockedpacks;
193 unsigned int disablexdccinfo;
194 unsigned int need_voice;
195 unsigned int noautorejoin;
196 unsigned int auto_crc_check;
197 unsigned int nocrc32;
198 unsigned int direct_file_access;
199 unsigned int autoaddann_short;
200 unsigned int spaces_in_filenames;
201 unsigned int restrictsend_warning;
202 unsigned int extend_status_line;
203 unsigned int include_subdirs;
204 unsigned int xdcclist_by_privmsg;
205 unsigned int balanced_queue;
206 unsigned int passive_dcc;
207 unsigned int upnp_router;
208 unsigned int http_search;
209 unsigned int old_statefile;
210 unsigned int direct_config_access;
211 unsigned int show_date_added;
212 unsigned int fish_only;
213 unsigned int privmsg_encrypt;
214 unsigned int verbose_crc32;
215 unsigned int mirc_dcc64;
216 unsigned int no_minspeed_on_free;
217 unsigned int no_status_chat;
218 unsigned int no_status_log;
219 unsigned int no_auto_rehash;
220 unsigned int send_batch;
221 unsigned int http_geoip;
222 unsigned int no_find_trigger;
223 unsigned int hide_list_stop;
224 unsigned int passive_dcc_chat;
225 unsigned int respondtochannelxdcc;
226 unsigned int respondtochannellist;
227 unsigned int quietmode;
f3dbc7c - no_natural_sort
cvs authored
228 unsigned int no_natural_sort;
d16d738 - requeue_sends
cvs authored
229 unsigned int requeue_sends;
07aaac6 Initial revision
dm authored
230
4e6d055 - convert to unsigned
cvs authored
231 context_t context_log[MAXCONTEXTS];
07aaac6 Initial revision
dm authored
232 ir_boutput_t stdout_buffer;
4e6d055 - convert to unsigned
cvs authored
233 off_t max_file_size;
234 time_t startuptime;
235 time_t nomd5_start;
236 time_t noannounce_start;
237 time_t noautosave;
238 time_t nonewcons;
239 time_t nolisting;
240 time_t last_logrotate;
241 time_t last_update;
07aaac6 Initial revision
dm authored
242 time_t curtime;
4e6d055 - convert to unsigned
cvs authored
243 long totaluptime;
3b5da2d - prefer long for 64bit
cvs authored
244 ir_uint64 curtimems;
2ff5b99 - use ir_int64
cvs authored
245 ir_int64 totalsent;
07aaac6 Initial revision
dm authored
246 unsigned long xdccsent[XDCC_SENT_SIZE];
b1b9a08 extend_status_line
dm authored
247 unsigned long xdccrecv[XDCC_SENT_SIZE];
248 unsigned long xdccsum[XDCC_SENT_SIZE];
07aaac6 Initial revision
dm authored
249
4e6d055 - convert to unsigned
cvs authored
250 irlist_t msglog;
251 irlist_t dccchats;
07aaac6 Initial revision
dm authored
252 irlist_t ignorelist;
253 irlist_t xdccs;
254 irlist_t mainqueue;
3e6578e - idlequeue
dm authored
255 irlist_t idlequeue;
07aaac6 Initial revision
dm authored
256 irlist_t trans;
257 irlist_t uploads;
4e6d055 - convert to unsigned
cvs authored
258 irlist_t console_history;
259 irlist_t listen_ports;
07aaac6 Initial revision
dm authored
260
4e6d055 - convert to unsigned
cvs authored
261 fd_set readset, writeset, execset;
07aaac6 Initial revision
dm authored
262
4e6d055 - convert to unsigned
cvs authored
263 struct
264 {
265 xdcc *xpack;
266 struct MD5Context md5sum;
267 int file_fd;
268 int dummy;
269 } md5build;
270
271 crc32build_t crc32build;
272
273 meminfo_t *meminfo;
274 char *r_pidfile;
275 char *console_input_line;
276 unsigned char *sendbuff;
277 char *const *argv;
07aaac6 Initial revision
dm authored
278 #if !defined(NO_CHROOT)
210c040 - drop getop and rewite cli
dm authored
279 const char *chrootdir;
07aaac6 Initial revision
dm authored
280 #endif
281 #if !defined(NO_SETUID)
210c040 - drop getop and rewite cli
dm authored
282 const char *runasuser;
07aaac6 Initial revision
dm authored
283 #endif
7ca52da - commandline -w dir
cvs authored
284 const char *workdir;
0266974 - new CLI: -i mybot.xdcc
dm authored
285 const char *import;
07aaac6 Initial revision
dm authored
286
4e6d055 - convert to unsigned
cvs authored
287 float r_transferminspeed, r_transfermaxspeed;
07aaac6 Initial revision
dm authored
288
4e6d055 - convert to unsigned
cvs authored
289 /* rehash temp variables */
290 unsigned int networks_online;
291 unsigned int r_networks_online;
292 unsigned int r_xdcclist_grouponly;
293 unsigned int support_groups;
294 unsigned int transferlimits_over;
295 unsigned int maxb;
296 unsigned int adjustcore;
297 unsigned int overallmaxspeeddaytimestart, overallmaxspeeddaytimeend;
298 unsigned int periodicmsg_time;
299 int ignore;
07aaac6 Initial revision
dm authored
300
4e6d055 - convert to unsigned
cvs authored
301 /* screen */
302 unsigned int attop, needsclear, termcols, termlines, nocolor, noscreen;
303 unsigned int curcol;
304 unsigned int console_history_offset;
305 unsigned int num_dccchats;
306 unsigned int stdout_buffer_init;
307
308 struct termios startup_tio;
309
310 float record;
311 float sentrecord;
312 unsigned int exiting;
313 unsigned int crashing;
314 unsigned int needsrehash;
315 unsigned int needsshutdown;
316 unsigned int needsswitch;
317 unsigned int needsreap;
318 unsigned int delayedshutdown;
319 unsigned int cursendptr;
320 unsigned int next_tr_id;
321 unsigned int context_cur_ptr;
296266b - make maxtrans debugable
cvs authored
322 unsigned int maxtrans;
323 unsigned int udummy;
4e6d055 - convert to unsigned
cvs authored
324
325 int max_fds_from_rlimit;
326 int logfd;
327
328 unsigned int meminfo_count;
329 unsigned int meminfo_depth;
b864d5d auto_crc_check
dm authored
330
07aaac6 Initial revision
dm authored
331 enum
332 {
333 #ifdef HAVE_FREEBSD_SENDFILE
334 TRANSFERMETHOD_FREEBSD_SENDFILE,
335 #endif
336 #ifdef HAVE_LINUX_SENDFILE
337 TRANSFERMETHOD_LINUX_SENDFILE,
338 #endif
339 #ifdef HAVE_MMAP
340 TRANSFERMETHOD_MMAP,
341 #endif
342 TRANSFERMETHOD_READ_WRITE,
343 } transfermethod;
344
4e6d055 - convert to unsigned
cvs authored
345 unsigned int needrestart;
07aaac6 Initial revision
dm authored
346 } gdata_t;
347
348
f87917f - porting to cparser
cvs authored
349 extern gdata_t gdata;
07aaac6 Initial revision
dm authored
350
351
352 #endif
353
354 /* End of File */
Something went wrong with that request. Please try again.