19147Seric /* 234920Sbostic * Copyright (c) 1983 Eric P. Allman 333728Sbostic * Copyright (c) 1988 Regents of the University of California. 433728Sbostic * All rights reserved. 533728Sbostic * 642825Sbostic * %sccs.include.redist.c% 733728Sbostic * 8*59723Seric * @(#)conf.h 6.28 (Berkeley) 05/04/93 933728Sbostic */ 109147Seric 1122726Sdist /* 1222726Sdist ** CONF.H -- All user-configurable parameters for sendmail 1322726Sdist */ 149147Seric 1557232Seric # include <sys/param.h> 1659389Seric # include <sys/stat.h> 1758689Seric # include <fcntl.h> 1857232Seric 199147Seric /* 209147Seric ** Table sizes, etc.... 219147Seric ** There shouldn't be much need to change these.... 229147Seric */ 239147Seric 2459303Seric # define MAXLINE 2048 /* max line length */ 2524945Seric # define MAXNAME 256 /* max length of a name */ 269147Seric # define MAXPV 40 /* max # of parms to mailers */ 2759303Seric # define MAXATOM 200 /* max atoms per address */ 289147Seric # define MAXMAILERS 25 /* maximum mailers known to system */ 2957143Seric # define MAXRWSETS 100 /* max # of sets of rewriting rules */ 309147Seric # define MAXPRIORITIES 25 /* max values for Precedence: field */ 3157143Seric # define MAXMXHOSTS 20 /* max # of MX records */ 3252106Seric # define SMTPLINELIM 990 /* maximum SMTP line length */ 3357232Seric # define MAXKEY 128 /* maximum size of a database key */ 3457232Seric # define MEMCHUNKSIZE 1024 /* chunk size for memory allocation */ 3559056Seric # define MAXUSERENVIRON 100 /* max envars saved, must be >= 3 */ 3658106Seric # define MAXIPADDR 16 /* max # of IP addrs for this host */ 3759667Seric # define MAXALIASDB 12 /* max # of alias databases */ 3859303Seric # define PSBUFSIZE (MAXLINE + MAXATOM) /* size of prescan buffer */ 3957143Seric 4057143Seric # ifndef QUEUESIZE 4157143Seric # define QUEUESIZE 1000 /* max # of jobs per queue run */ 4257143Seric # endif 4357143Seric 4452107Seric # ifndef FORK 4552107Seric # define FORK vfork /* function to call to fork mailer */ 4652107Seric # endif 479147Seric 489147Seric /* 499147Seric ** Compilation options. 5025673Seric ** 5125673Seric ** #define these if they are available; comment them out otherwise. 529147Seric */ 539147Seric 5425673Seric # define LOG 1 /* enable logging */ 5525673Seric # define UGLYUUCP 1 /* output ugly UUCP From lines */ 5658778Seric # define NETINET 1 /* include internet support */ 5725673Seric # define SETPROCTITLE 1 /* munge argv to display current status */ 5835651Seric # define NAMED_BIND 1 /* use Berkeley Internet Domain Server */ 5953735Seric # define MATCHGECOS 1 /* match user names from gecos field */ 6036483Sbostic 6156337Seric # ifdef NEWDB 6256337Seric # define USERDB 1 /* look in user database (requires NEWDB) */ 6356823Seric # define BTREE_MAP 1 /* enable BTREE mapping type (requires NEWDB) */ 6457143Seric # define HASH_MAP 1 /* enable HASH mapping type (requires NEWDB) */ 6556337Seric # endif 6656337Seric 67*59723Seric # ifdef NIS 68*59723Seric # define NIS_ALIASES 1 /* include NIS support for aliases */ 69*59723Seric # define NIS_MAP 1 /* include NIS mapping type */ 70*59723Seric # endif 71*59723Seric 7256823Seric # ifdef NDBM 7356823Seric # define DBM_MAP 1 /* enable DBM mapping type (requires NDBM) */ 7456823Seric # endif 7556823Seric 7656823Seric /* 7759023Seric ** Operating system configuration. 7859023Seric ** 7959023Seric ** Unless you are porting to a new OS, you shouldn't have to 8059023Seric ** change these. 8156823Seric */ 8256823Seric 8359348Seric # ifdef __hpux 8456823Seric # define SYSTEM5 1 8556823Seric # endif 8656823Seric 8751918Seric # ifdef SYSTEM5 8855418Seric 8951918Seric # define LOCKF 1 /* use System V lockf instead of flock */ 9055418Seric # define SYS5TZ 1 /* use System V style timezones */ 9157943Seric # define HASUNAME 1 /* use System V uname system call */ 9255418Seric 9359074Seric # endif 9459074Seric 9559023Seric #ifdef sun 9659023Seric # include <vfork.h> 9759023Seric #endif 9859023Seric 9959287Seric #ifdef _POSIX_VERSION 10059287Seric # define HASSETSID 1 /* has setsid(2) call */ 10159287Seric #endif 10259287Seric 10359288Seric #ifdef NeXT 10459288Seric # define sleep sleepX 10559288Seric #endif 10659288Seric 10759074Seric /* 10859092Seric ** Due to a "feature" in some operating systems such as Ultrix 4.3 and 10959092Seric ** HPUX 8.0, if you receive a "No route to host" message (ICMP message 11059092Seric ** ICMP_UNREACH_HOST) on _any_ connection, all connections to that host 11159092Seric ** are closed. Some firewalls return this error if you try to connect 11259092Seric ** to the IDENT port (113), so you can't receive email from these hosts 11359092Seric ** on these systems. The firewall really should use a more specific 11459092Seric ** message such as ICMP_UNREACH_PROTOCOL or _PORT or _NET_PROHIB. 11559074Seric */ 11651918Seric 11759348Seric #if !defined(ultrix) && !defined(__hpux) 11859074Seric # define IDENTPROTO 1 /* use IDENT proto (RFC 1413) */ 11959074Seric #endif 12059074Seric 12150537Seric /* 12259023Seric ** Remaining definitions should never have to be changed. They are 12359023Seric ** primarily to provide back compatibility for older systems -- for 12459287Seric ** example, it includes some POSIX compatibility definitions 12559287Seric */ 12659023Seric 12759388Seric /* System 5 compatibility */ 12859388Seric #ifndef S_ISREG 12959388Seric #define S_ISREG(foo) ((foo & S_IFREG) == S_IFREG) 13059388Seric #endif 13159388Seric #ifndef S_IWGRP 13259388Seric #define S_IWGRP 020 13359388Seric #endif 13459388Seric #ifndef S_IWOTH 13559388Seric #define S_IWOTH 002 13659388Seric #endif 13759388Seric 13859023Seric /* 13950537Seric ** Older systems don't have this error code -- it should be in 14050537Seric ** /usr/include/sysexits.h. 14150537Seric */ 14250537Seric 14350537Seric # ifndef EX_CONFIG 14450537Seric # define EX_CONFIG 78 /* configuration error */ 14550537Seric # endif 14656852Seric 14756852Seric /* 14858778Seric ** Do some required dependencies 14958778Seric */ 15058778Seric 15158778Seric #if defined(NETINET) || defined(NETISO) 15259107Seric # define SMTP 1 /* enable user and server SMTP */ 15359107Seric # define QUEUE 1 /* enable queueing */ 15459107Seric # define DAEMON 1 /* include the daemon (requires IPC & SMTP) */ 15558778Seric #endif 15658778Seric 15758778Seric 15858778Seric /* 15956852Seric ** Arrange to use either varargs or stdargs 16056852Seric */ 16156852Seric 16256852Seric # ifdef __STDC__ 16356852Seric 16456852Seric # include <stdarg.h> 16556852Seric 16656852Seric # define VA_LOCAL_DECL va_list ap; 16756852Seric # define VA_START(f) va_start(ap, f) 16856852Seric # define VA_END va_end(ap) 16956852Seric 17056852Seric # else 17156852Seric 17256852Seric # include <varargs.h> 17356852Seric 17456852Seric # define VA_LOCAL_DECL va_list ap; 17556852Seric # define VA_START(f) va_start(ap) 17656852Seric # define VA_END va_end(ap) 17756852Seric 17856852Seric # endif 17957631Seric 18057943Seric #ifdef HASUNAME 18157631Seric # include <sys/utsname.h> 18257631Seric # ifdef newstr 18357631Seric # undef newstr 18457631Seric # endif 18557943Seric #else /* ! HASUNAME */ 18657631Seric # define NODE_LENGTH 32 18757631Seric struct utsname 18857631Seric { 18957631Seric char nodename[NODE_LENGTH+1]; 19057631Seric }; 19157943Seric #endif /* HASUNAME */ 19257642Seric 19357735Seric #ifndef MAXHOSTNAMELEN 19457735Seric #define MAXHOSTNAMELEN 256 19557735Seric #endif 19658153Seric 19758153Seric #if !defined(SIGCHLD) && defined(SIGCLD) 19858153Seric # define SIGCHLD SIGCLD 19958153Seric #endif 20058153Seric 20158153Seric #ifndef STDIN_FILENO 20258153Seric #define STDIN_FILENO 0 20358153Seric #endif 20458153Seric 20558153Seric #ifndef STDOUT_FILENO 20658153Seric #define STDOUT_FILENO 1 20758153Seric #endif 20858153Seric 20958153Seric #ifndef STDERR_FILENO 21058153Seric #define STDERR_FILENO 2 21158153Seric #endif 21258689Seric 21358689Seric #ifdef LOCKF 21458689Seric #define LOCK_SH 0x01 /* shared lock */ 21558689Seric #define LOCK_EX 0x02 /* exclusive lock */ 21658689Seric #define LOCK_NB 0x04 /* non-blocking lock */ 21759447Seric #define LOCK_UN 0x08 /* unlock */ 21858692Seric 21958692Seric #else 22058692Seric 22158692Seric # include <sys/file.h> 22258692Seric 22358689Seric #endif 22458702Seric 22558702Seric /* 22658702Seric ** Size of tobuf (deliver.c) 22758702Seric ** Tweak this to match your syslog implementation. It will have to 22858702Seric ** allow for the extra information printed. 22958702Seric */ 23058702Seric 23158702Seric #ifndef TOBUFSIZE 23258702Seric # define TOBUFSIZE (1024 - 256) 23358702Seric #endif 234