Generate Multi-Master Replication configuration for OpenLDAP
[tprouty/samba.git] / source / setup / slapd.conf
1 loglevel 0
2
3 ### Multimaster-ServerIDs and URLs ###
4
5 ${MMR_SERVERIDS_CONFIG}
6
7
8 include ${LDAPDIR}/backend-schema.schema
9
10 pidfile         ${LDAPDIR}/slapd.pid
11 argsfile        ${LDAPDIR}/slapd.args
12 sasl-realm ${DNSDOMAIN}
13
14 #authz-regexp
15 #          uid=([^,]*),cn=${DNSDOMAIN},cn=digest-md5,cn=auth
16 #          ldap:///${DOMAINDN}??sub?(samAccountName=\$1)
17
18 #authz-regexp
19 #          uid=([^,]*),cn=([^,]*),cn=digest-md5,cn=auth
20 #          ldap:///${DOMAINDN}??sub?(samAccountName=\$1)
21
22 authz-regexp
23           uid=([^,]*),cn=([^,]*),cn=digest-md5,cn=auth
24           ldap:///cn=samba??one?(cn=\$1)
25
26 authz-regexp
27           uid=([^,]*),cn=([^,]*),cn=ntlm,cn=auth
28           ldap:///cn=samba??one?(cn=\$1)
29
30 access to dn.base="" 
31        by dn=cn=samba-admin,cn=samba manage
32        by anonymous read
33        by * read
34
35 access to dn.subtree="cn=samba"
36        by anonymous auth
37
38 access to dn.subtree="${DOMAINDN}"
39        by dn=cn=samba-admin,cn=samba manage
40        by dn=cn=manager manage
41        by * none
42
43 password-hash   {CLEARTEXT}
44
45 include ${LDAPDIR}/modules.conf
46
47 defaultsearchbase ${DOMAINDN}
48
49 rootdn cn=Manager
50
51 ${REFINT_CONFIG}
52
53 ${MEMBEROF_CONFIG}
54
55 database        ldif
56 suffix          cn=Samba
57 directory       ${LDAPDIR}/db/samba
58 rootdn          cn=Manager,cn=Samba
59
60 ########################################
61 ### cn=schema ###
62 database        hdb
63 suffix          ${SCHEMADN}
64 rootdn          cn=Manager,${SCHEMADN}
65 rootpw          linux
66 directory       ${LDAPDIR}/db/schema
67 index           objectClass eq
68 index           samAccountName eq
69 index name eq
70 index objectCategory eq
71 index lDAPDisplayName eq
72 index subClassOf eq
73 index cn eq
74 index entryUUID,entryCSN eq
75
76 #syncprov is stable in OpenLDAP 2.3, and available in 2.2.  
77 #We only need this for the contextCSN attribute anyway....
78 overlay syncprov
79 syncprov-sessionlog 100
80 # syncprov-checkpoint 100 10
81
82
83 ### Multimaster-Replication of cn=schema Subcontext ###
84 ${MMR_SYNCREPL_SCHEMA_CONFIG}
85 ${MIRRORMODE}
86
87 #########################################
88 ### cn=config ###
89 database        hdb
90 suffix          ${CONFIGDN}
91 rootdn          cn=Manager,${CONFIGDN}
92 rootpw          linux
93 directory       ${LDAPDIR}/db/config
94 index           objectClass eq
95 index           samAccountName eq
96 index name eq
97 index objectSid eq
98 index objectCategory eq
99 index nCName eq
100 index subClassOf eq
101 index dnsRoot eq
102 index nETBIOSName eq
103 index cn eq
104 index entryUUID,entryCSN eq
105
106 #syncprov is stable in OpenLDAP 2.3, and available in 2.2.  
107 #We only need this for the contextCSN attribute anyway....
108 overlay syncprov
109 syncprov-sessionlog 100
110 # syncprov-checkpoint 100 10
111
112 ### Multimaster-Replication of cn=config Subcontext ###
113 ${MMR_SYNCREPL_CONFIG_CONFIG}
114 ${MIRRORMODE}
115
116 ########################################
117 ### cn=users /base-dn  ###
118 database        hdb
119 suffix          ${DOMAINDN}
120 rootdn          cn=Manager,${DOMAINDN}
121 rootpw          linux
122 directory       ${LDAPDIR}/db/user
123 index           objectClass eq
124 index           samAccountName eq
125 index name eq
126 index objectSid eq
127 index objectCategory eq
128 index member eq
129 index uidNumber eq
130 index gidNumber eq
131 index nCName eq
132 index lDAPDisplayName eq
133 index subClassOf eq
134 index dnsRoot eq
135 index nETBIOSName eq
136 index cn eq
137 index entryUUID,entryCSN eq
138
139 #syncprov is stable in OpenLDAP 2.3, and available in 2.2.  
140 #We only need this for the contextCSN attribute anyway....
141 overlay syncprov
142 syncprov-sessionlog 100
143 # syncprov-checkpoint 100 10
144
145 ### Multimaster-Replication of cn=user/base-dn context ###
146 ${MMR_SYNCREPL_USER_CONFIG}
147 ${MIRRORMODE}