]> git.sur5r.net Git - openldap/blob - tests/data/slapd-acl.conf
Add back-ndb
[openldap] / tests / data / slapd-acl.conf
1 # master slapd config -- for testing
2 # $OpenLDAP$
3 ## This work is part of OpenLDAP Software <http://www.openldap.org/>.
4 ##
5 ## Copyright 1998-2008 The OpenLDAP Foundation.
6 ## All rights reserved.
7 ##
8 ## Redistribution and use in source and binary forms, with or without
9 ## modification, are permitted only as authorized by the OpenLDAP
10 ## Public License.
11 ##
12 ## A copy of this license is available in the file LICENSE in the
13 ## top-level directory of the distribution or, alternatively, at
14 ## <http://www.OpenLDAP.org/license.html>.
15
16 include         @SCHEMADIR@/core.schema
17 include         @SCHEMADIR@/cosine.schema
18 include         @SCHEMADIR@/inetorgperson.schema
19 include         @SCHEMADIR@/openldap.schema
20 include         @SCHEMADIR@/nis.schema
21 pidfile         @TESTDIR@/slapd.1.pid
22 argsfile        @TESTDIR@/slapd.1.args
23
24 # global ACLs
25 #
26 # normal installations should protect root dse, cn=monitor, cn=subschema
27 #
28
29 access          to dn.exact="" attrs=objectClass
30                 by users read
31 access          to *
32                 by * read
33
34 #mod#modulepath ../servers/slapd/back-@BACKEND@/
35 #mod#moduleload back_@BACKEND@.la
36 #monitormod#modulepath ../servers/slapd/back-monitor/
37 #monitormod#moduleload back_monitor.la
38
39 #######################################################################
40 # database definitions
41 #######################################################################
42
43 database        @BACKEND@
44
45 suffix          "dc=example,dc=com"
46 directory       @TESTDIR@/db.1.a
47 rootdn          "cn=Manager,dc=example,dc=com"
48 rootpw          secret
49 #bdb#index              objectClass     eq
50 #bdb#index              cn,sn,uid       pres,eq,sub
51 #hdb#index              objectClass     eq
52 #hdb#index              cn,sn,uid       pres,eq,sub
53 #ndb#dbname db_1
54 #ndb#include @DATADIR@/ndb.conf
55
56 #access         to attrs=objectclass dn.subtree="dc=example,dc=com"
57 access          to attrs=objectclass
58                 by * =rsc stop
59
60 #access         to filter="(objectclass=person)" attrs=userpassword dn.subtree="dc=example,dc=com"
61 access          to filter="(objectclass=person)" attrs=userpassword
62                 by anonymous auth
63                 by self =wx
64
65 access          to dn.exact="cn=Mark Elliot,ou=Alumni Association,ou=People,dc=example,dc=com"
66                         attrs=cn val="Mark A Elliot"
67                 by dn="cn=Barbara Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com" read
68                 by * break
69
70 access          to dn.exact="cn=Mark Elliot,ou=Alumni Association,ou=People,dc=example,dc=com"
71                         attrs=cn val="Mark Elliot"
72                 by dn="cn=Bjorn Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com" read
73                 by * break
74
75 access          to dn.exact="cn=Mark Elliot,ou=Alumni Association,ou=People,dc=example,dc=com"
76                         attrs=cn
77                 by * search
78
79 access          to dn.exact="cn=John Doe,ou=Information Technology Division,ou=People,dc=example,dc=com"
80                         attrs=cn val.regex="^John D.+"
81                 by dn="cn=Barbara Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com" read
82                 by * break
83
84 access          to dn.exact="cn=John Doe,ou=Information Technology Division,ou=People,dc=example,dc=com"
85                         attrs=cn val.regex="^Jonath.+"
86                 by dn="cn=Bjorn Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com" read
87                 by * break
88
89 access          to dn.exact="cn=John Doe,ou=Information Technology Division,ou=People,dc=example,dc=com"
90                         attrs=cn
91                 by * search
92
93 access          to dn.onelevel="ou=Information Technology Division,ou=People,dc=example,dc=com"
94                         filter="(cn=*Jensen)"
95                         attrs=cn val.regex=".*Jensen$"
96                 by dn="cn=Barbara Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com" read
97                 by dn="cn=Bjorn Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com" read
98                 by * break
99
100 access          to dn.exact="cn=Bjorn Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com"
101                         attrs=cn
102                 by * search
103
104 access          to dn.children="ou=Alumni Association,ou=People,dc=example,dc=com"
105                 by dn.regex=".+,dc=example,dc=com" +c continue
106                 by dn.subtree="dc=example,dc=com" +rs continue
107                 by dn.children="dc=example,dc=com" +d continue
108                 by * stop
109
110 #access         to attrs=member,uniquemember dn.subtree="dc=example,dc=com"
111 access          to attrs=member,uniquemember
112                 by dn.exact="cn=James A Jones 1,ou=Alumni Association,ou=People,dc=example,dc=com" selfwrite
113                 by dnattr=member selfwrite
114                 by dnattr=uniquemember selfwrite
115                 by * read
116
117 #access         to attrs=member,uniquemember filter="(mail=*com)" dn.subtree="dc=example,dc=com"
118 access          to attrs=member,uniquemember filter="(mail=*com)"
119                 by * read
120
121 #access         to filter="(|(objectclass=groupofnames)(objectClass=groupofuniquenames))" dn.subtree="dc=example,dc=com"
122 access          to filter="(|(objectclass=groupofnames)(objectClass=groupofuniquenames))"
123                 by dn.exact="cn=Bjorn Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com" =sc continue
124                 by dn.regex="^cn=Bjorn Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com$" +rw stop
125                 by * break
126
127 access          to dn.children="ou=Information Technology Division,ou=People,dc=example,dc=com"
128                 by group/groupOfUniqueNames/uniqueMember.exact="cn=ITD Staff,ou=Groups,dc=example,dc=com" write
129                 by * read
130
131 access          to dn.exact="cn=Alumni Assoc Staff,ou=Groups,dc=example,dc=com"
132                 by set="[cn=Alumni Assoc Staff,ou=Groups,dc=example,dc=com]/member* & user" write
133                 by * read
134
135 #access         to filter="(name=X*Y*Z)" dn.subtree="dc=example,dc=com"
136 access          to filter="(name=X*Y*Z)"
137                 by * continue
138
139 access          to dn.subtree="ou=Add & Delete,dc=example,dc=com"
140                 by dn.exact="cn=Bjorn Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com" add
141                 by dn.exact="cn=Barbara Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com" delete
142                 by dn.exact="cn=James A Jones 1,ou=Alumni Association,ou=People,dc=example,dc=com" write
143                 by * read
144
145 # fall into global ACLs
146
147 #monitor#database       monitor