2 * Copyright (c) 1990 Regents of the University of Michigan.
5 * Redistribution and use in source and binary forms are permitted
6 * provided that this notice is preserved and that due credit is given
7 * to the University of Michigan at Ann Arbor. The name of the University
8 * may not be used to endorse or promote products derived from this
9 * software without specific prior written permission. This software
10 * is provided ``as is'' without express or implied warranty.
13 #ifndef _LDAPD_COMMON_H
14 #define _LDAPD_COMMON_H 1
17 * This structure represents an association to a dsa. There is one of
18 * these for each association open (a new association is made for each
19 * new dsa, and for each dn).
23 int c_ad; /* association descriptor */
24 char *c_dn; /* the dn this asoc is bound as */
25 char *c_cred; /* corresponding pw */
27 unsigned long c_method;
28 struct PSAPaddr *c_paddr; /* the dsa address */
29 int c_time; /* time this association inited */
30 int c_refcnt; /* number of ops referencing this ad */
35 * This structure represents an outstanding request. There is one of
36 * these for each client request for which we have not yet received a
37 * response from a dsa.
41 int m_msgid; /* the message id */
42 int m_uniqid; /* unique id for this message */
43 int m_msgtype; /* the ldap operation type */
44 LDAPMod *m_mods; /* for modify operations only */
45 BerElement *m_ber; /* the unparsed ber for the op */
46 struct conn *m_conn; /* connection structure */
47 #ifdef LDAP_CONNECTIONLESS
48 int m_cldap; /* connectionless transport? (CLDAP) */
49 struct sockaddr m_clientaddr; /* client address (if using CLDAP) */
50 DN m_searchbase; /* base used in search */
51 #endif /* LDAP_CONNECTIONLESS */
55 #define DEFAULT_TIMEOUT 3600 /* idle client connections */
56 #define DEFAULT_REFERRAL_TIMEOUT 900 /* DSA connections */
58 #include "proto-ldapd.h"
62 extern char *dsa_address;
63 extern char *bound_dn, *bound_pw;
64 struct PSAPaddr *psap_cpy(struct PSAPaddr *);
66 /* in association.c */
67 extern struct conn *conns;
71 extern int ldap_debug;
75 extern int ldap_compat;
79 #ifdef LDAP_CONNECTIONLESS
83 extern int referral_connection_timeout;
84 extern struct timeval conn_start_tv;
86 extern char *krb_ldap_service;
87 extern char *krb_x500_service;
88 extern char *krb_x500_instance;
89 extern char *krb_x500_nonce;
90 extern char *kerberos_keyfile;
94 extern short ldap_photo_syntax;
95 extern short ldap_jpeg_syntax;
96 extern short ldap_jpeg_nonfile_syntax;
97 extern short ldap_audio_syntax;
98 extern short ldap_dn_syntax;
99 extern short ldap_postaladdress_syntax;
100 extern short ldap_acl_syntax;
101 extern short ldap_mtai_syntax;
102 extern short ldap_rts_cred_syntax;
103 extern short ldap_rtl_syntax;
104 extern short ldap_mailbox_syntax;
105 extern short ldap_caseignorelist_syntax;
106 extern short ldap_caseexactstring_syntax;
107 extern short ldap_certif_syntax;
108 extern short ldap_iattr_syntax;
109 extern short ldap_telex_syntax;
110 extern short ldap_octetstring_syntax;
111 extern short ldap_deliverymethod_syntax;
112 extern short ldap_facsimileTelephoneNumber_syntax;
113 extern short ldap_presentationAddress_syntax;
114 extern short ldap_teletexTerminalIdentifier_syntax;
115 extern short ldap_searchGuide_syntax;
116 extern short ldap_dLSubmitPermission_syntax;
119 extern char Versionstr[];