]> git.sur5r.net Git - openldap/blob - doc/man/man8/slapacl.8
387d84d37d537af7a727b4b1a28bba2c2ebab487
[openldap] / doc / man / man8 / slapacl.8
1 .TH SLAPACL 8C "RELEASEDATE" "OpenLDAP LDVERSION"
2 .\" Copyright 2004-2009 The OpenLDAP Foundation All Rights Reserved.
3 .\" Copying restrictions apply.  See COPYRIGHT/LICENSE.
4 .\" $OpenLDAP$
5 .SH NAME
6 slapacl \- Check access to a list of attributes.
7 .SH SYNOPSIS
8 .B SBINDIR/slapacl
9 .B \-b DN
10 .B [\-d level]
11 .B [\-D authcDN | \-U authcID]
12 .B [\-f slapd.conf]
13 .B [\-F confdir]
14 .B [\-o name[=value]]
15 .B [\-u]
16 .B [\-v]
17 .B [\-X authzID | \-o authzDN=DN]
18 .B [attr[/access][:value]] [...]
19 .LP
20 .SH DESCRIPTION
21 .LP
22 .B Slapacl
23 is used to check the behavior of the slapd in verifying access to data
24 according to ACLs, as specified in 
25 .BR slapd.access (5).
26 It opens the
27 .BR slapd.conf (5)
28 configuration file, reads in the 
29 .B access
30 directives, and then parses the 
31 .B attr
32 list given on the command-line; if none is given, access to the
33 .B entry
34 pseudo-attribute is tested.
35 .LP
36 .SH OPTIONS
37 .TP
38 .BI \-b " DN"
39 specify the 
40 .B DN 
41 which access is requested to; the corresponding entry is fetched 
42 from the database, and thus it must exist.
43 The DN is also used to determine what rules apply; thus, it must be
44 in the naming context of a configured database.  See also
45 .BR \-u .
46 .TP
47 .BI \-d " level"
48 enable debugging messages as defined by the specified
49 .IR level ;
50 see
51 .BR slapd (8)
52 for details.
53 .TP
54 .BI \-D " authcDN"
55 specify a DN to be used as identity through the test session
56 when selecting appropriate
57 .B <by> 
58 clauses in access lists.
59 .TP
60 .BI \-f " slapd.conf"
61 specify an alternative
62 .BR slapd.conf (5)
63 file.
64 .TP
65 .BI \-F " confdir"
66 specify a config directory.
67 If both
68 .B -f
69 and
70 .B -F
71 are specified, the config file will be read and converted to
72 config directory format and written to the specified directory.
73 If neither option is specified, an attempt to read the
74 default config directory will be made before trying to use the default
75 config file. If a valid config directory exists then the
76 default config file is ignored.
77 .TP
78 .BI \-o " option[=value]"
79 Specify an
80 .BR option
81 with a(n optional)
82 .BR value .
83 Possible generic options/values are:
84 .LP
85 .nf
86               syslog=<subsystems>  (see `\-s' in slapd(8))
87               syslog-level=<level> (see `\-S' in slapd(8))
88               syslog-user=<user>   (see `\-l' in slapd(8))
89
90 .fi
91 .RS
92 Possible options/values specific to
93 .B slapacl
94 are:
95 .RE
96 .nf
97
98               authzDN
99               domain
100               peername
101               sasl_ssf
102               sockname
103               sockurl
104               ssf
105               tls_ssf
106               transport_ssf
107
108 .fi
109 .RS
110 See the related fields in
111 .BR slapd.access (5)
112 for details.
113 .RE
114 .TP
115 .BI \-u
116 do not fetch the entry from the database.
117 In this case, if the entry does not exist, a fake entry with the DN
118 given with the
119 .B \-b
120 option is used, with no attributes.
121 As a consequence, those rules that depend on the contents 
122 of the target object will not behave as with the real object.
123 The DN given with the
124 .B \-b
125 option is still used to select what rules apply; thus, it must be
126 in the naming context of a configured database.
127 See also
128 .BR \-b .
129 .TP
130 .BI \-U " authcID"
131 specify an ID to be mapped to a 
132 .B DN 
133 as by means of 
134 .B authz-regexp
135 or
136 .B authz-rewrite
137 rules (see 
138 .BR slapd.conf (5)
139 for details); mutually exclusive with
140 .BR \-D .
141 .TP
142 .B \-v
143 enable verbose mode.
144 .TP
145 .BI \-X " authzID"
146 specify an authorization ID to be mapped to a
147 .B DN
148 as by means of
149 .B authz-regexp
150 or
151 .B authz-rewrite
152 rules (see
153 .BR slapd.conf (5)
154 for details); mutually exclusive with \fB\-o\fP \fIauthzDN=DN\fP.
155 .SH EXAMPLES
156 The command
157 .LP
158 .nf
159 .ft tt
160         SBINDIR/slapacl -f ETCDIR/slapd.conf -v \\
161             -U bjorn -b "o=University of Michigan,c=US" \\
162             "o/read:University of Michigan"
163
164 .ft
165 .fi
166 tests whether the user
167 .I bjorn
168 can access the attribute 
169 .I o
170 of the entry
171 .I o=University of Michigan,c=US
172 at
173 .I read
174 level.
175 .SH "SEE ALSO"
176 .BR ldap (3),
177 .BR slapd (8)
178 .BR slaptest (8)
179 .BR slapauth (8)
180 .LP
181 "OpenLDAP Administrator's Guide" (http://www.OpenLDAP.org/doc/admin/)
182 .SH ACKNOWLEDGEMENTS
183 .so ../Project