summaryrefslogtreecommitdiffstats
path: root/contrib/sendmail/include
diff options
context:
space:
mode:
authorgshapiro <gshapiro@FreeBSD.org>2002-04-10 03:05:00 +0000
committergshapiro <gshapiro@FreeBSD.org>2002-04-10 03:05:00 +0000
commit9e3bd35cd79720a6547b183a6a6fb97ab1ae7b84 (patch)
tree348e6162af337e0b74db963f6e4dcc567e2f99e9 /contrib/sendmail/include
parent1a7e50d796833cbb4346a251bc88555ea2c58e94 (diff)
downloadFreeBSD-src-9e3bd35cd79720a6547b183a6a6fb97ab1ae7b84.zip
FreeBSD-src-9e3bd35cd79720a6547b183a6a6fb97ab1ae7b84.tar.gz
Import sendmail 8.12.3
Diffstat (limited to 'contrib/sendmail/include')
-rw-r--r--contrib/sendmail/include/libmilter/mfapi.h18
-rw-r--r--contrib/sendmail/include/libmilter/milter.h4
-rw-r--r--contrib/sendmail/include/sm/cdefs.h8
-rw-r--r--contrib/sendmail/include/sm/conf.h17
-rw-r--r--contrib/sendmail/include/sm/config.h18
-rw-r--r--contrib/sendmail/include/sm/gen.h4
-rw-r--r--contrib/sendmail/include/sm/io.h14
-rw-r--r--contrib/sendmail/include/sm/ldap.h53
-rw-r--r--contrib/sendmail/include/sm/os/sm_os_freebsd.h8
9 files changed, 107 insertions, 37 deletions
diff --git a/contrib/sendmail/include/libmilter/mfapi.h b/contrib/sendmail/include/libmilter/mfapi.h
index 506fcf3..ad3e0ff 100644
--- a/contrib/sendmail/include/libmilter/mfapi.h
+++ b/contrib/sendmail/include/libmilter/mfapi.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999-2001 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 1999-2002 Sendmail, Inc. and its suppliers.
* All rights reserved.
*
* By using this file, you agree to the terms and conditions set
@@ -7,7 +7,7 @@
* the sendmail distribution.
*
*
- * $Id: mfapi.h,v 8.35 2001/10/09 19:05:24 gshapiro Exp $
+ * $Id: mfapi.h,v 8.41 2002/03/22 21:36:12 gshapiro Exp $
*/
/*
@@ -17,12 +17,12 @@
#ifndef _LIBMILTER_MFAPI_H
# define _LIBMILTER_MFAPI_H 1
+# include <sys/types.h>
# include <sys/socket.h>
# include "libmilter/mfdef.h"
# define LIBMILTER_API extern
-# include <sys/types.h>
#ifndef _SOCK_ADDR
# define _SOCK_ADDR struct sockaddr
@@ -108,6 +108,7 @@ struct smfiDesc
LIBMILTER_API int smfi_register __P((struct smfiDesc));
LIBMILTER_API int smfi_main __P((void));
+LIBMILTER_API int smfi_setbacklog __P((int));
LIBMILTER_API int smfi_setdbg __P((int));
LIBMILTER_API int smfi_settimeout __P((int));
LIBMILTER_API int smfi_setconn __P((char *));
@@ -371,6 +372,17 @@ LIBMILTER_API int smfi_addrcpt __P((SMFICTX *, char *));
LIBMILTER_API int smfi_delrcpt __P((SMFICTX *, char *));
+#if _FFR_SMFI_PROGRESS
+/*
+** Send a "no-op" up to the MTA to tell it we're still alive, so long
+** milter-side operations don't time out.
+**
+** SMFICTX *ctx; Opaque context structure
+*/
+
+LIBMILTER_API int smfi_progress __P((SMFICTX *));
+#endif /* _FFR_SMFI_PROGRESS */
+
/*
** Delete a recipient from the envelope
**
diff --git a/contrib/sendmail/include/libmilter/milter.h b/contrib/sendmail/include/libmilter/milter.h
index b714c3e..d9378faf 100644
--- a/contrib/sendmail/include/libmilter/milter.h
+++ b/contrib/sendmail/include/libmilter/milter.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999-2001 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 1999-2002 Sendmail, Inc. and its suppliers.
* All rights reserved.
*
* By using this file, you agree to the terms and conditions set
@@ -7,7 +7,7 @@
* the sendmail distribution.
*
*
- * $Id: milter.h,v 8.35 2001/06/27 21:46:44 gshapiro Exp $
+ * $Id: milter.h,v 8.37 2002/03/22 19:32:48 ca Exp $
*/
/*
diff --git a/contrib/sendmail/include/sm/cdefs.h b/contrib/sendmail/include/sm/cdefs.h
index b8597d9..bb5e4c1 100644
--- a/contrib/sendmail/include/sm/cdefs.h
+++ b/contrib/sendmail/include/sm/cdefs.h
@@ -1,12 +1,12 @@
/*
- * Copyright (c) 2000-2001 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 2000-2002 Sendmail, Inc. and its suppliers.
* 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: cdefs.h,v 1.14 2001/06/07 20:04:53 ca Exp $
+ * $Id: cdefs.h,v 1.15 2002/01/16 18:30:11 ca Exp $
*/
/*
@@ -43,7 +43,9 @@
# define __END_DECLS
# endif /* defined(__cplusplus) */
# if defined(__STDC__) || defined(__cplusplus)
-# define __P(protos) protos
+# ifndef __P
+# define __P(protos) protos
+# endif /* __P */
# define __CONCAT(x,y) x ## y
# define __STRING(x) #x
# else /* defined(__STDC__) || defined(__cplusplus) */
diff --git a/contrib/sendmail/include/sm/conf.h b/contrib/sendmail/include/sm/conf.h
index f54cd96..7770f54 100644
--- a/contrib/sendmail/include/sm/conf.h
+++ b/contrib/sendmail/include/sm/conf.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1998-2001 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 1998-2002 Sendmail, Inc. and its suppliers.
* All rights reserved.
* Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved.
* Copyright (c) 1988, 1993
@@ -10,7 +10,7 @@
* the sendmail distribution.
*
*
- * $Id: conf.h,v 1.82 2001/12/20 16:14:48 ca Exp $
+ * $Id: conf.h,v 1.87 2002/04/02 08:11:52 gshapiro Exp $
*/
/*
@@ -105,6 +105,7 @@
# define SMRSH_CMDDIR "/var/adm/sm.bin"
# endif /* HPUX10 */
# ifdef HPUX11
+# define HASSETREUID 1 /* setreuid(2) works on HP-UX 11.x */
# define HASFCHOWN 1 /* has fchown(2) */
# ifndef BROKEN_RES_SEARCH
# define BROKEN_RES_SEARCH 1 /* res_search(unknown) returns h_errno=0 */
@@ -618,6 +619,15 @@ extern long dgux_inet_addr();
# ifndef _PATH_SENDMAILPID
# define _PATH_SENDMAILPID "/var/run/sendmail.pid"
# endif /* ! _PATH_SENDMAILPID */
+# if _FFR_DIGUNIX_SAFECHOWN
+/*
+** Testing on a Digital UNIX 4.0a system showed this to be the correct
+** setting but given the security consequences, more testing and
+** verification is needed. Unfortunately, the man page offers no
+** assistance.
+*/
+# define IS_SAFE_CHOWN >= 0
+# endif /* _FFR_DIGUNIX_SAFECHOWN */
# endif /* __osf__ */
@@ -716,6 +726,9 @@ typedef int pid_t;
# define SPT_TYPE SPT_PSSTRINGS
# define SPT_PADCHAR '\0' /* pad process title with nulls */
# define ERRLIST_PREDEFINED /* don't declare sys_errlist */
+# ifndef NOT_SENDMAIL
+# define sleep sleepX
+# endif /* ! NOT_SENDMAIL */
# endif /* defined(DARWIN) */
diff --git a/contrib/sendmail/include/sm/config.h b/contrib/sendmail/include/sm/config.h
index de34a76..791a525 100644
--- a/contrib/sendmail/include/sm/config.h
+++ b/contrib/sendmail/include/sm/config.h
@@ -6,7 +6,7 @@
* forth in the LICENSE file which can be found at the top level of
* the sendmail distribution.
*
- * $Id: config.h,v 1.42 2001/06/17 21:31:11 ca Exp $
+ * $Id: config.h,v 1.44 2002/01/23 17:47:15 gshapiro Exp $
*/
/*
@@ -143,4 +143,20 @@
# define SM_CONF_TEST_LLONG 1
# endif /* !SM_CONF_TEST_LLONG */
+/* Does LDAP library have ldap_memfree()? */
+# ifndef SM_CONF_LDAP_MEMFREE
+
+/*
+** The new LDAP C API (draft-ietf-ldapext-ldap-c-api-04.txt) includes
+** ldap_memfree() in the API. That draft states to use LDAP_API_VERSION
+** of 2004 to identify the API.
+*/
+
+# if USING_NETSCAPE_LDAP || LDAP_API_VERSION >= 2004
+# define SM_CONF_LDAP_MEMFREE 1
+# else /* USING_NETSCAPE_LDAP || LDAP_API_VERSION >= 2004 */
+# define SM_CONF_LDAP_MEMFREE 0
+# endif /* USING_NETSCAPE_LDAP || LDAP_API_VERSION >= 2004 */
+# endif /* ! SM_CONF_LDAP_MEMFREE */
+
#endif /* ! SM_CONFIG_H */
diff --git a/contrib/sendmail/include/sm/gen.h b/contrib/sendmail/include/sm/gen.h
index b250705..61b6e1b 100644
--- a/contrib/sendmail/include/sm/gen.h
+++ b/contrib/sendmail/include/sm/gen.h
@@ -1,12 +1,12 @@
/*
- * Copyright (c) 2000-2001 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 2000-2002 Sendmail, Inc. and its suppliers.
* 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: gen.h,v 1.19 2001/09/11 04:04:43 gshapiro Exp $
+ * $Id: gen.h,v 1.22 2002/04/03 00:40:42 ca Exp $
*/
/*
diff --git a/contrib/sendmail/include/sm/io.h b/contrib/sendmail/include/sm/io.h
index b95ede5..48b358d 100644
--- a/contrib/sendmail/include/sm/io.h
+++ b/contrib/sendmail/include/sm/io.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000-2001 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 2000-2002 Sendmail, Inc. and its suppliers.
* All rights reserved.
* Copyright (c) 1990
* The Regents of the University of California. All rights reserved.
@@ -11,7 +11,7 @@
* forth in the LICENSE file which can be found at the top level of
* the sendmail distribution.
*
- * $Id: io.h,v 1.19 2001/07/10 21:56:46 gshapiro Exp $
+ * $Id: io.h,v 1.23 2002/02/23 19:32:17 gshapiro Exp $
*/
/*-
@@ -46,6 +46,7 @@
#define SM_IO_WHAT_ISTYPE 5
#define SM_IO_IS_READABLE 6
#define SM_IO_WHAT_TIMEOUT 7
+#define SM_IO_WHAT_SIZE 8
/* info flags (exposed) */
#define SM_IO_FTYPE_CREATE 1
@@ -111,13 +112,12 @@ struct sm_file
off_t (*f_seek) __P((SM_FILE_T *, off_t, int));
ssize_t (*f_write) __P((SM_FILE_T *, const char *, size_t));
int (*f_open) __P((SM_FILE_T *, const void *, int,
- const void *));
+ const void *));
int (*f_setinfo) __P((SM_FILE_T *, int , void *));
int (*f_getinfo) __P((SM_FILE_T *, int , void *));
int f_timeout;
int f_timeoutstate; /* either blocking or non-blocking */
char *f_type; /* for by-type lookups */
- void *f_self; /* self for reference */
struct sm_file *f_flushfp; /* flush this before reading parent */
struct sm_file *f_modefp; /* sync mode with this fp */
@@ -130,9 +130,6 @@ struct sm_file
unsigned char f_ubuf[3]; /* guarantee an ungetc() buffer */
unsigned char f_nbuf[1]; /* guarantee a getc() buffer */
- /* separate buffer for fgetln() when line crosses buffer boundary */
- struct smbuf f_lb; /* buffer for fgetln() */
-
/* Unix stdio files get aligned to block boundaries on fseek() */
int f_blksize; /* stat.st_blksize (may be != bf.size) */
off_t f_lseekoff; /* current lseek offset */
@@ -224,8 +221,7 @@ __END_DECLS
#define SMOFF 0x004000 /* set iff offset is in fact correct */
#define SMALC 0x010000 /* allocate string space dynamically */
-#define SMACCESSMASK 0x0070
-#define SMMODEMASK 0x011C
+#define SMMODEMASK 0x0070 /* read/write mode */
/* defines for timeout constants */
#define SM_TIME_IMMEDIATE (0)
diff --git a/contrib/sendmail/include/sm/ldap.h b/contrib/sendmail/include/sm/ldap.h
index 7deec8b..dfa0463 100644
--- a/contrib/sendmail/include/sm/ldap.h
+++ b/contrib/sendmail/include/sm/ldap.h
@@ -6,7 +6,7 @@
* forth in the LICENSE file which can be found at the top level of
* the sendmail distribution.
*
- * $Id: ldap.h,v 1.9 2002/01/11 22:06:50 gshapiro Exp $
+ * $Id: ldap.h,v 1.22 2002/03/05 02:17:26 ca Exp $
*/
#ifndef SM_LDAP_H
@@ -15,6 +15,11 @@
# include <sm/conf.h>
# include <sm/rpool.h>
+/*
+** NOTE: These should be changed from LDAPMAP_* to SM_LDAP_*
+** in the next major release (8.13) of sendmail.
+*/
+
# ifndef LDAPMAP_MAX_ATTR
# define LDAPMAP_MAX_ATTR 64
# endif /* ! LDAPMAP_MAX_ATTR */
@@ -30,22 +35,31 @@
# if _FFR_LDAP_RECURSION
/* Attribute types */
-# define LDAPMAP_ATTR_NORMAL 0
-# define LDAPMAP_ATTR_DN 1
-# define LDAPMAP_ATTR_FILTER 2
-# define LDAPMAP_ATTR_URL 3
-# define LDAPMAP_ATTR_FINAL 4
+# define SM_LDAP_ATTR_NONE (-1)
+# define SM_LDAP_ATTR_OBJCLASS 0
+# define SM_LDAP_ATTR_NORMAL 1
+# define SM_LDAP_ATTR_DN 2
+# define SM_LDAP_ATTR_FILTER 3
+# define SM_LDAP_ATTR_URL 4
/* sm_ldap_results() flags */
# define SM_LDAP_SINGLEMATCH 0x0001
# define SM_LDAP_MATCHONLY 0x0002
+# define SM_LDAP_USE_ALLATTR 0x0004
+
# endif /* _FFR_LDAP_RECURSION */
struct sm_ldap_struct
{
/* needed for ldap_open or ldap_init */
- char *ldap_host;
+ char *ldap_target;
int ldap_port;
+# if _FFR_LDAP_URI
+ bool ldap_uri;
+# endif /* _FFR_LDAP_URI */
+# if _FFR_LDAP_SETVERSION
+ int ldap_version;
+# endif /* _FFR_LDAP_SETVERSION */
pid_t ldap_pid;
/* options set in ld struct before ldap_bind_s */
@@ -67,7 +81,7 @@ struct sm_ldap_struct
char *ldap_attr[LDAPMAP_MAX_ATTR + 1];
# if _FFR_LDAP_RECURSION
int ldap_attr_type[LDAPMAP_MAX_ATTR + 1];
- char *ldap_attr_final[LDAPMAP_MAX_ATTR + 1];
+ char *ldap_attr_needobjclass[LDAPMAP_MAX_ATTR + 1];
# endif /* _FFR_LDAP_RECURSION */
bool ldap_attrsonly;
@@ -85,13 +99,21 @@ struct sm_ldap_struct
typedef struct sm_ldap_struct SM_LDAP_STRUCT;
# if _FFR_LDAP_RECURSION
-struct sm_ldap_recurse_list
+struct sm_ldap_recurse_entry
{
char *lr_search;
int lr_type;
- struct sm_ldap_recurse_list *lr_next;
+ bool lr_done;
};
+struct sm_ldap_recurse_list
+{
+ int lr_size;
+ int lr_cnt;
+ struct sm_ldap_recurse_entry **lr_data;
+};
+
+typedef struct sm_ldap_recurse_entry SM_LDAP_RECURSE_ENTRY;
typedef struct sm_ldap_recurse_list SM_LDAP_RECURSE_LIST;
# endif /* _FFR_LDAP_RECURSION */
@@ -100,13 +122,18 @@ extern void sm_ldap_clear __P((SM_LDAP_STRUCT *));
extern bool sm_ldap_start __P((char *, SM_LDAP_STRUCT *));
extern int sm_ldap_search __P((SM_LDAP_STRUCT *, char *));
# if _FFR_LDAP_RECURSION
-extern int sm_ldap_results __P((SM_LDAP_STRUCT *, int, int, char,
- SM_RPOOL_T *, char **,
+extern int sm_ldap_results __P((SM_LDAP_STRUCT *, int, int, int,
+ SM_RPOOL_T *, char **, int *, int *,
SM_LDAP_RECURSE_LIST *));
# endif /* _FFR_LDAP_RECURSION */
extern void sm_ldap_setopts __P((LDAP *, SM_LDAP_STRUCT *));
extern int sm_ldap_geterrno __P((LDAP *));
extern void sm_ldap_close __P((SM_LDAP_STRUCT *));
-# endif /* LDAPMAP */
+/* Portability defines */
+# if !SM_CONF_LDAP_MEMFREE
+# define ldap_memfree(x) ((void) 0)
+# endif /* !SM_CONF_LDAP_MEMFREE */
+
+# endif /* LDAPMAP */
#endif /* ! SM_LDAP_H */
diff --git a/contrib/sendmail/include/sm/os/sm_os_freebsd.h b/contrib/sendmail/include/sm/os/sm_os_freebsd.h
index 8edc718..d900ba7 100644
--- a/contrib/sendmail/include/sm/os/sm_os_freebsd.h
+++ b/contrib/sendmail/include/sm/os/sm_os_freebsd.h
@@ -6,7 +6,7 @@
* forth in the LICENSE file which can be found at the top level of
* the sendmail distribution.
*
- * $Id: sm_os_freebsd.h,v 1.9 2001/06/27 21:46:48 gshapiro Exp $
+ * $Id: sm_os_freebsd.h,v 1.10 2002/03/10 22:41:03 gshapiro Exp $
*/
/*
@@ -31,7 +31,11 @@
#endif
#ifndef SM_CONF_SHM
-# define SM_CONF_SHM 1
+# ifdef __sparc64__
+# define SM_CONF_SHM 0
+# else /* __sparc64__ */
+# define SM_CONF_SHM 1
+# endif /* __sparc64__ */
#endif /* SM_CONF_SHM */
#ifndef SM_CONF_SEM
# define SM_CONF_SEM 1
OpenPOWER on IntegriCloud