2
* (c) Copyright 1992 by Panagiotis Tsirigotis
3
* (c) Sections Copyright 1998-2001 by Rob Braun
4
* All rights reserved. The file named COPYRIGHT specifies the terms
5
* and conditions for redistribution.
12
* $Id: xconfig.h,v 1.1.1.1 2003/02/19 17:29:28 bbraun Exp $
16
* Deal with stupid Compaq (DEC) Unix problem ...
23
* The purpose of customconf.h is to allow the override of
24
* constants defined in this file. These include all constants that
25
* cannot be overriden from the command line via some option.
28
#include "customconf.h"
32
#define DEFAULT_CONFIG_FILE "/etc/xinetd.conf"
35
* This is the facility used by xinetd to log syslog messages
37
#define DEFAULT_SYSLOG_FACILITY LOG_DAEMON
40
* This is the level used for log messages when a service logs to syslog
42
#define DEFAULT_SERVICE_SYSLOG_LEVEL LOG_INFO
45
* Max number of concurrently running processes forked to get
46
* the user id from the remote host
48
#define DEFAULT_LOGPROCS 15
51
* The loop rate is a bound on the rate of forking servers for a
52
* particular service. If that rate is exceeded, the service is deactivated.
54
#define DEFAULT_LOOP_RATE 50
57
* The number of seconds to wait before re-enabling a looping service.
59
#define DEFAULT_LOOP_TIME 10
62
* Signal-to-action mapping
64
#ifndef RECONFIG_HARD_SIG
65
#define RECONFIG_HARD_SIG SIGHUP
67
#ifndef OLD_RECONFIG_HARD_SIG
68
#define OLD_RECONFIG_HARD_SIG SIGUSR2
70
#ifndef TERMINATION_SIG
71
#define TERMINATION_SIG SIGTERM
73
#ifndef STATE_DUMP_SIG
74
#define STATE_DUMP_SIG SIGUSR1
76
#ifndef CONSISTENCY_CHECK_SIG
77
#define CONSISTENCY_CHECK_SIG SIGIOT
79
#ifndef SERVER_EXIT_SIG
80
#define SERVER_EXIT_SIG SIGCHLD
83
#define QUIT_SIG SIGQUIT
87
* This is the file where the internal state of xinetd is dumped upon
88
* receipt of STATE_DUMP_SIG
91
#define DUMP_FILE "/var/run/xinetd.dump"
95
* There are 2 timeouts (in seconds) when trying to get the user id from
96
* the remote host. Any timeout value specified as 0 implies an infinite
98
* LOGUSER_SUCCESS_TIMEOUT is the timeout when access control has been passed
99
* and a new process has been forked to exec the server.
100
* LOGUSER_FAILURE_TIMEOUT is the timeout when the attempt to access the
101
* service has been rejected.
103
* Both timeouts should be at least 30 seconds as suggested in RFC 1413
104
* (assuming they are not 'infinite' timeouts).
106
#ifndef LOGUSER_SUCCESS_TIMEOUT
107
#define LOGUSER_SUCCESS_TIMEOUT 30
109
#ifndef LOGUSER_FAILURE_TIMEOUT
110
#define LOGUSER_FAILURE_TIMEOUT 30
114
* This is used when an instance limit is not specified for a service
115
* and the defaults entry does not specify an instance limit either.
116
* It can be a positive number or "UNLIMITED".
118
#ifndef DEFAULT_INSTANCE_LIMIT
119
#define DEFAULT_INSTANCE_LIMIT UNLIMITED
123
* This is the interval (in seconds) over which we check if the service
124
* loop rate has been exceeded.
126
#ifndef LOOP_INTERVAL
127
#define LOOP_INTERVAL 2
131
* LOG_OPEN_FLAGS are the flags used to open a log file (this is used as
132
* the 3rd argument of open(2))
134
#ifndef LOG_OPEN_FLAGS
135
#define LOG_OPEN_FLAGS O_CREAT+O_APPEND+O_WRONLY
139
* Number of consecutive fork failures that we are willing to put up with
142
#ifndef MAX_FORK_FAILURES
143
#define MAX_FORK_FAILURES 5
147
* This is the time period during which we will not log subsequest attempts
148
* to access a datagram-based service from the same bad address after logging
150
* For example, if we receive a datagram at time t from address A which
151
* has a match in the no_access list, we will log the failed attempt and
152
* during the interval (t, t+DGRAM_IGNORE_TIME) we will not log attempts
153
* from address A (for the same service).
154
* In this context, the address is defined as (IP address, port number).
156
#ifndef DGRAM_IGNORE_TIME
157
#define DGRAM_IGNORE_TIME 60 /* seconds */
160
#ifndef DUMP_FILE_MODE
161
#define DUMP_FILE_MODE 0644
164
#ifndef LOG_FILE_MODE
165
#define LOG_FILE_MODE 0644
169
* The DATAGRAM_SIZE should be big enough for an ethernet packet
171
#ifndef DATAGRAM_SIZE
172
#define DATAGRAM_SIZE 2048
176
* Time interval between retry attempts
178
#ifndef RETRY_INTERVAL
179
#define RETRY_INTERVAL 5 /* seconds */
183
* LOG_EXTRA_MIN, LOG_EXTRA_MAX define the limits by which the hard limit
184
* on the log size can exceed the soft limit
186
#ifndef LOG_EXTRA_MIN
187
#define LOG_EXTRA_MIN ( 5 * 1024 )
189
#ifndef LOG_EXTRA_MAX
190
#define LOG_EXTRA_MAX ( 20 * 1024 )
194
* If SENSORS are used and someone trips it, they are added to the
195
* global_no_access table for whatever the configured time is. This
196
* define determines the size of the table to use.
198
#define MAX_GLOBAL_NO_ACCESS 10240
201
#endif /* CONFIG_H */