1 /* 2 * Copyright (c) 2006 Sendmail, Inc. and its suppliers. 3 * All rights reserved. 4 * 5 * By using this file, you agree to the terms and conditions set 6 * forth in the LICENSE file which can be found at the top level of 7 * the sendmail distribution. 8 * 9 * $Id: daemon.h,v 8.3 2006/07/13 22:57:03 ca Exp $ 10 */ 11 12 #pragma ident "%Z%%M% %I% %E% SMI" 13 14 #ifndef DAEMON_H 15 #define DAEMON_H 1 16 17 #if DAEMON_C 18 # define EXTERN 19 #else 20 # define EXTERN extern 21 #endif 22 23 /* structure to describe a daemon or a client */ 24 struct daemon 25 { 26 int d_socket; /* fd for socket */ 27 SOCKADDR d_addr; /* socket for incoming */ 28 unsigned short d_port; /* port number */ 29 int d_listenqueue; /* size of listen queue */ 30 int d_tcprcvbufsize; /* size of TCP receive buffer */ 31 int d_tcpsndbufsize; /* size of TCP send buffer */ 32 time_t d_refuse_connections_until; 33 bool d_firsttime; 34 int d_socksize; 35 BITMAP256 d_flags; /* flags; see sendmail.h */ 36 char *d_mflags; /* flags for use in macro */ 37 char *d_name; /* user-supplied name */ 38 39 int d_dm; /* DeliveryMode */ 40 int d_refuseLA; 41 int d_queueLA; 42 int d_delayLA; 43 int d_maxchildren; 44 45 #if MILTER 46 char *d_inputfilterlist; 47 struct milter *d_inputfilters[MAXFILTERS]; 48 #endif /* MILTER */ 49 #if _FFR_SS_PER_DAEMON 50 int d_supersafe; 51 #endif /* _FFR_SS_PER_DAEMON */ 52 }; 53 54 typedef struct daemon DAEMON_T; 55 56 EXTERN DAEMON_T Daemons[MAXDAEMONS]; 57 58 #define DPO_NOTSET (-1) /* daemon option (int) not set */ 59 /* see also sendmail.h: SuperSafe values */ 60 61 extern bool refuseconnections __P((ENVELOPE *, int, bool)); 62 63 #undef EXTERN 64 #endif /* ! DAEMON_H */ 65