summaryrefslogtreecommitdiffstats
path: root/contrib/sendmail/src/conf.h
blob: 86a4b240607a1ad4df9a46a20d5594490d4d338d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
/*
 * Copyright (c) 1998-2001 Sendmail, Inc. and its suppliers.
 *	All rights reserved.
 * Copyright (c) 1983, 1995-1997 Eric P. Allman.  All rights reserved.
 * Copyright (c) 1988, 1993
 *	The Regents of the University of California.  All rights reserved.
 *
 * By using this file, you agree to the terms and conditions set
 * forth in the LICENSE file which can be found at the top level of
 * the sendmail distribution.
 *
 *
 *	$Id: conf.h,v 8.557 2001/10/05 03:49:41 ca Exp $
 */

/*
**  CONF.H -- All user-configurable parameters for sendmail
**
**	Send updates to sendmail@Sendmail.ORG so they will be
**	included in the next release.
*/

#ifndef CONF_H
#define CONF_H 1

#ifdef __GNUC__
struct rusage;	/* forward declaration to get gcc to shut up in wait.h */
#endif /* __GNUC__ */

# include <sys/param.h>
# include <sys/types.h>
# include <sys/stat.h>
# ifndef __QNX__
/* in QNX this grabs bogus LOCK_* manifests */
#  include <sys/file.h>
# endif /* ! __QNX__ */
# include <sys/wait.h>
# include <limits.h>
# include <fcntl.h>
# include <signal.h>
# include <netdb.h>
# include <pwd.h>
# include <grp.h>

/* make sure TOBUFSIZ isn't larger than system limit for size of exec() args */
#ifdef ARG_MAX
# if ARG_MAX > 4096
#  define SM_ARG_MAX	4096
# else /* ARG_MAX > 4096 */
#  define SM_ARG_MAX	ARG_MAX
# endif /* ARG_MAX > 4096 */
#else /* ARG_MAX */
# define SM_ARG_MAX	4096
#endif /* ARG_MAX */

/**********************************************************************
**  Table sizes, etc....
**	There shouldn't be much need to change these....
**	If you do, be careful, none should be set anywhere near INT_MAX
**********************************************************************/

#define MAXLINE		2048		/* max line length */
#define MAXNAME		256		/* max length of a name */
#define MAXPV		256		/* max # of parms to mailers */
#define MAXATOM		1000		/* max atoms per address */
#define MAXRWSETS	200		/* max # of sets of rewriting rules */
#define MAXPRIORITIES	25		/* max values for Precedence: field */
#define MAXMXHOSTS	100		/* max # of MX records for one host */
#define SMTPLINELIM	990		/* maximum SMTP line length */
#define MAXKEY		128		/* maximum size of a database key */
#define MEMCHUNKSIZE	1024		/* chunk size for memory allocation */
#define MAXUSERENVIRON	100		/* max envars saved, must be >= 3 */
#define MAXMAPSTACK	12		/* max # of stacked or sequenced maps */
#if MILTER
# define MAXFILTERS	25		/* max # of milter filters */
# define MAXFILTERMACROS 50		/* max # of macros per milter cmd */
#endif /* MILTER */
#define MAXSMTPARGS	20		/* max # of ESMTP args for MAIL/RCPT */
#define MAXTOCLASS	8		/* max # of message timeout classes */
#define MAXRESTOTYPES	3		/* max # of resolver timeout types */
#define MAXMIMEARGS	20		/* max args in Content-Type: */
#define MAXMIMENESTING	20		/* max MIME multipart nesting */
#define QUEUESEGSIZE	1000		/* increment for queue size */

/*
**  MAXQFNAME == 2 (size of "qf", "df" prefix)
**	+ 8 (base 60 encoded date, time & sequence number)
**	+ 10 (base 10 encoded 32 bit process id)
**	+ 1 (terminating NUL character).
*/

#define MAXQFNAME	21		/* max qf file name length + 1 */
#define MACBUFSIZE	4096		/* max expanded macro buffer size */
#define TOBUFSIZE	SM_ARG_MAX	/* max buffer to hold address list */
#define MAXSHORTSTR	203		/* max short string length */
#define MAXMACNAMELEN	25		/* max macro name length */
#define MAXMACROID	0377		/* max macro id number */
					/* Must match (BITMAPBITS - 1) */
#ifndef MAXHDRSLEN
# define MAXHDRSLEN	(32 * 1024)	/* max size of message headers */
#endif /* ! MAXHDRSLEN */
#define MAXDAEMONS	10		/* max number of ports to listen to */
#ifndef MAXINTERFACES
# define MAXINTERFACES	512		/* number of interfaces to probe */
#endif /* MAXINTERFACES */
#ifndef MAXSYMLINKS
# define MAXSYMLINKS	32		/* max number of symlinks in a path */
#endif /* ! MAXSYMLINKS */
#define MAXLINKPATHLEN	(MAXPATHLEN * MAXSYMLINKS) /* max link-expanded file */
#define DATA_PROGRESS_TIMEOUT	300	/* how often to check DATA progress */
#define ENHSCLEN	10		/* max len of enhanced status code */
#define DEFAULT_MAX_RCPT	100	/* max number of RCPTs per envelope */
#define MAXQUEUEGROUPS	50		/* max # of queue groups */
	/* must be less than BITMAPBITS for DoQueueRun */
#define MAXWORKGROUPS	50		/* max # of work groups */
#define MAXFILESYS	BITMAPBITS	/* max # of queue file systems
					 * must be <= BITMAPBITS */
#ifndef FILESYS_UPDATE_INTERVAL
# define FILESYS_UPDATE_INTERVAL 300	/* how often to update FileSys table */
#endif /* FILESYS_UPDATE_INTERVAL */

#ifndef SM_DEFAULT_TTL
# define SM_DEFAULT_TTL 3600 /* default TTL for services that don't have one */
#endif /* SM_DEFAULT_TTL */

#if SASL
# ifndef AUTH_MECHANISMS
#  if STARTTLS
#   define AUTH_MECHANISMS	"EXTERNAL GSSAPI KERBEROS_V4 DIGEST-MD5 CRAM-MD5"
#  else /* STARTTLS */
#   define AUTH_MECHANISMS	"GSSAPI KERBEROS_V4 DIGEST-MD5 CRAM-MD5"
#  endif /* STARTTLS */
# endif /* ! AUTH_MECHANISMS */
#endif /* SASL */

/**********************************************************************
**  Compilation options.
**	#define these to 1 if they are available;
**	#define them to 0 otherwise.
**  All can be overridden from Makefile.
**********************************************************************/

#ifndef NETINET
# define NETINET	1	/* include internet support */
#endif /* ! NETINET */

#ifndef NETINET6
# define NETINET6	0	/* do not include IPv6 support */
#endif /* ! NETINET6 */

#ifndef NETISO
# define NETISO	0		/* do not include ISO socket support */
#endif /* ! NETISO */

#ifndef NAMED_BIND
# define NAMED_BIND	1	/* use Berkeley Internet Domain Server */
#endif /* ! NAMED_BIND */

#ifndef XDEBUG
# define XDEBUG		1	/* enable extended debugging */
#endif /* ! XDEBUG */

#ifndef MATCHGECOS
# define MATCHGECOS	1	/* match user names from gecos field */
#endif /* ! MATCHGECOS */

#ifndef DSN
# define DSN		1	/* include delivery status notification code */
#endif /* ! DSN */

#if !defined(USERDB) && (defined(NEWDB) || defined(HESIOD))
# define USERDB		1	/* look in user database */
#endif /* !defined(USERDB) && (defined(NEWDB) || defined(HESIOD)) */

#ifndef MIME8TO7
# define MIME8TO7	1	/* 8->7 bit MIME conversions */
#endif /* ! MIME8TO7 */

#ifndef MIME7TO8
# define MIME7TO8	1	/* 7->8 bit MIME conversions */
#endif /* ! MIME7TO8 */

#if NAMED_BIND
# ifndef DNSMAP
#  define DNSMAP	1	/* DNS map type */
# endif /* ! DNSMAP */
#endif /* NAMED_BIND */

#ifndef PIPELINING
# define PIPELINING	1	/* SMTP PIPELINING */
#endif /* PIPELINING */

/**********************************************************************
**  End of site-specific configuration.
**********************************************************************/

#include <sm/conf.h>

#endif /* ! CONF_H */
OpenPOWER on IntegriCloud