| 1 | /* |
| 2 | * Copyright (c) 1983 Eric P. Allman |
| 3 | * Copyright (c) 1988 Regents of the University of California. |
| 4 | * All rights reserved. |
| 5 | * |
| 6 | * %sccs.include.redist.c% |
| 7 | * |
| 8 | * @(#)conf.h 6.11 (Berkeley) %G% |
| 9 | */ |
| 10 | |
| 11 | /* |
| 12 | ** CONF.H -- All user-configurable parameters for sendmail |
| 13 | */ |
| 14 | |
| 15 | # include <sys/param.h> |
| 16 | # include <fcntl.h> |
| 17 | |
| 18 | /* |
| 19 | ** Table sizes, etc.... |
| 20 | ** There shouldn't be much need to change these.... |
| 21 | */ |
| 22 | |
| 23 | # define MAXLINE 1024 /* max line length */ |
| 24 | # define MAXNAME 256 /* max length of a name */ |
| 25 | # define MAXPV 40 /* max # of parms to mailers */ |
| 26 | # define MAXATOM 100 /* max atoms per address */ |
| 27 | # define MAXMAILERS 25 /* maximum mailers known to system */ |
| 28 | # define MAXRWSETS 100 /* max # of sets of rewriting rules */ |
| 29 | # define MAXPRIORITIES 25 /* max values for Precedence: field */ |
| 30 | # define MAXMXHOSTS 20 /* max # of MX records */ |
| 31 | # define SMTPLINELIM 990 /* maximum SMTP line length */ |
| 32 | # define MAXKEY 128 /* maximum size of a database key */ |
| 33 | # define MEMCHUNKSIZE 1024 /* chunk size for memory allocation */ |
| 34 | # define MAXUSERENVIRON 100 /* max envariables saved */ |
| 35 | # define MAXIPADDR 16 /* max # of IP addrs for this host */ |
| 36 | # define PSBUFSIZE (MAXNAME * 4) /* size of prescan buffer */ |
| 37 | |
| 38 | # ifndef QUEUESIZE |
| 39 | # define QUEUESIZE 1000 /* max # of jobs per queue run */ |
| 40 | # endif |
| 41 | |
| 42 | # ifndef FORK |
| 43 | # define FORK vfork /* function to call to fork mailer */ |
| 44 | # endif |
| 45 | |
| 46 | /* |
| 47 | ** Compilation options. |
| 48 | ** |
| 49 | ** #define these if they are available; comment them out otherwise. |
| 50 | */ |
| 51 | |
| 52 | # define LOG 1 /* enable logging */ |
| 53 | # define SMTP 1 /* enable user and server SMTP */ |
| 54 | # define QUEUE 1 /* enable queueing */ |
| 55 | # define UGLYUUCP 1 /* output ugly UUCP From lines */ |
| 56 | # define DAEMON 1 /* include the daemon (requires IPC & SMTP) */ |
| 57 | # define SETPROCTITLE 1 /* munge argv to display current status */ |
| 58 | # define NAMED_BIND 1 /* use Berkeley Internet Domain Server */ |
| 59 | # define MATCHGECOS 1 /* match user names from gecos field */ |
| 60 | |
| 61 | # ifdef NEWDB |
| 62 | # define USERDB 1 /* look in user database (requires NEWDB) */ |
| 63 | # define BTREE_MAP 1 /* enable BTREE mapping type (requires NEWDB) */ |
| 64 | # define HASH_MAP 1 /* enable HASH mapping type (requires NEWDB) */ |
| 65 | # endif |
| 66 | |
| 67 | # ifdef NDBM |
| 68 | # define DBM_MAP 1 /* enable DBM mapping type (requires NDBM) */ |
| 69 | # endif |
| 70 | |
| 71 | /* |
| 72 | ** Some general configuration -- you shouldn't have to touch these |
| 73 | */ |
| 74 | |
| 75 | # ifdef hpux |
| 76 | # define SYSTEM5 1 |
| 77 | # endif |
| 78 | |
| 79 | # ifdef SYSTEM5 |
| 80 | |
| 81 | # define LOCKF 1 /* use System V lockf instead of flock */ |
| 82 | # define SYS5TZ 1 /* use System V style timezones */ |
| 83 | # define HASUNAME 1 /* use System V uname system call */ |
| 84 | |
| 85 | # endif |
| 86 | |
| 87 | /* |
| 88 | ** Older systems don't have this error code -- it should be in |
| 89 | ** /usr/include/sysexits.h. |
| 90 | */ |
| 91 | |
| 92 | # ifndef EX_CONFIG |
| 93 | # define EX_CONFIG 78 /* configuration error */ |
| 94 | # endif |
| 95 | |
| 96 | /* |
| 97 | ** Arrange to use either varargs or stdargs |
| 98 | */ |
| 99 | |
| 100 | # ifdef __STDC__ |
| 101 | |
| 102 | # include <stdarg.h> |
| 103 | |
| 104 | # define VA_LOCAL_DECL va_list ap; |
| 105 | # define VA_START(f) va_start(ap, f) |
| 106 | # define VA_END va_end(ap) |
| 107 | |
| 108 | # else |
| 109 | |
| 110 | # include <varargs.h> |
| 111 | |
| 112 | # define VA_LOCAL_DECL va_list ap; |
| 113 | # define VA_START(f) va_start(ap) |
| 114 | # define VA_END va_end(ap) |
| 115 | |
| 116 | # endif |
| 117 | |
| 118 | #ifdef HASUNAME |
| 119 | # include <sys/utsname.h> |
| 120 | # ifdef newstr |
| 121 | # undef newstr |
| 122 | # endif |
| 123 | #else /* ! HASUNAME */ |
| 124 | # define NODE_LENGTH 32 |
| 125 | struct utsname |
| 126 | { |
| 127 | char nodename[NODE_LENGTH+1]; |
| 128 | }; |
| 129 | #endif /* HASUNAME */ |
| 130 | |
| 131 | #ifdef sun |
| 132 | # include <vfork.h> |
| 133 | #endif |
| 134 | |
| 135 | #ifndef MAXHOSTNAMELEN |
| 136 | #define MAXHOSTNAMELEN 256 |
| 137 | #endif |
| 138 | |
| 139 | #if !defined(SIGCHLD) && defined(SIGCLD) |
| 140 | # define SIGCHLD SIGCLD |
| 141 | #endif |
| 142 | |
| 143 | #ifndef STDIN_FILENO |
| 144 | #define STDIN_FILENO 0 |
| 145 | #endif |
| 146 | |
| 147 | #ifndef STDOUT_FILENO |
| 148 | #define STDOUT_FILENO 1 |
| 149 | #endif |
| 150 | |
| 151 | #ifndef STDERR_FILENO |
| 152 | #define STDERR_FILENO 2 |
| 153 | #endif |
| 154 | |
| 155 | #ifdef LOCKF |
| 156 | #define LOCK_SH 0x01 /* shared lock */ |
| 157 | #define LOCK_EX 0x02 /* exclusive lock */ |
| 158 | #define LOCK_NB 0x04 /* non-blocking lock */ |
| 159 | #endif |