]> git.sur5r.net Git - openldap/blob - doc/man/man5/slapd.conf.5
Update index description with substr varients and
[openldap] / doc / man / man5 / slapd.conf.5
1 .TH SLAPD.CONF 5 "20 August 2000" "OpenLDAP LDVERSION"
2 .\" $OpenLDAP$
3 .\" Copyright 1998-2000 The OpenLDAP Foundation All Rights Reserved.
4 .\" Copying restrictions apply.  See COPYRIGHT/LICENSE.
5 .SH NAME
6 slapd.conf \- configuration file for slapd, the stand-alone LDAP daemon
7 .SH SYNOPSIS
8 ETCDIR/slapd.conf
9 .SH DESCRIPTION
10 The file
11 .B ETCDIR/slapd.conf
12 contains configuration information for the
13 .BR slapd (8)
14 daemon.  This configuration file is also used by the
15 .BR slurpd (8)
16 replication daemon and by the SLAPD tools
17 .BR slapadd (8),
18 .BR slapcat (8),
19 and
20 .BR slapindex (8).
21 .LP
22 The
23 .B slapd.conf
24 file consists of a series of global configuration options that apply to
25 .B slapd
26 as a whole (including all backends), followed by zero or more database
27 backend definitions that contain information specific to a backend
28 instance.
29 .LP
30 The general format of
31 .B slapd.conf
32 is as follows:
33 .LP
34 .nf
35     # comment - these options apply to every database
36     <global configuration options>
37     # first database definition & configuration options
38     database    <backend 1 type>
39     <configuration options specific to backend 1>
40     # subsequent database definitions & configuration options
41     ...
42 .fi
43 .LP
44 As many backend-specific sections as desired may be included.  Global
45 options can be overridden in a backend (for options that appear more
46 than once, the last appearance in the
47 .B slapd.conf
48 file is used).  Blank lines and comment lines beginning with a `#'
49 character are ignored. If a line begins with white space, it is
50 considered a continuation of the previous line.
51 .LP
52 Arguments on configuration lines are separated by white space. If an
53 argument contains white space, the argument should be enclosed in
54 double quotes.  If an argument contains a double quote (`"') or a
55 backslash character (`\\'), the character should be preceded by a
56 backslash character.
57 .LP
58 The specific configuration options available are discussed below in the
59 Global Configuration Options, General Backend Options, LDBM
60 Backend-Specific Options, Shell Backend-Specific Options, and Password
61 Backend-Specific Options sections.  Refer to the "OpenLDAP
62 Administrator's Guide" for more details on the slapd configuration
63 file.
64 .SH GLOBAL CONFIGURATION OPTIONS
65 Options described in this section apply to all backends, unless specifically 
66 overridden in a backend definition. Arguments that should be replaced by 
67 actual text are shown in brackets <>.
68 .TP
69 .B access to <what> [ by <who> <access> <control> ]+
70 Grant access (specified by <access>) to a set of entries and/or
71 attributes (specified by <what>) by one or more requestors (specified
72 by <who>).
73 See the "OpenLDAP's Administrator's Guide" for details.
74 .TP
75 .B argsfile <filename>
76 The ( absolute ) name of a file that will hold the 
77 .B slapd
78 server's command line options
79 if started without the debugging command line option.
80 .HP
81 .hy 0
82 .B attributetype (\ <oid> [NAME\ <name>] [OBSOLETE]\
83  [DESC\ <description>]\
84  [SUP\ <oid>] [EQUALITY\ <oid>] [ORDERING\ <oid>]\
85  [SUBSTR\ <oid>] [SYNTAX\ <oidlen>] [SINGLE\-VALUE] [COLLECTIVE]\
86  [NO\-USER\-MODIFICATION] [USAGE\ <attributeUsage>]\ )
87 .RS
88 Specify an attribute type using the LDAPv3 syntax defined in RFC 2252.
89 The slapd parser extends the RFC 2252 definition by allowing string
90 forms as well as numeric OIDs to be used for the attribute OID and
91 attribute syntax OID.
92 (See the
93 .B objectidentifier
94 description.) Currently the syntax name parser is case-sensitive.
95 The known syntax names are:
96 .RS
97 .RS
98 .PD 0
99 AttributeTypeDescription Audio Binary BitString Certificate CertificateList
100 CertificatePair DN DeliveryMethod DirectoryString DITContentRuleDescription
101 DITStructureRuleDescription EnhancedGuide FacsimileTelephoneNumber
102 GeneralizedTime Guide IA5String Integer MatchingRuleDescription
103 MatchingRuleUseDescription MailPreference NameAndOptionalUUID
104 NameFormDescription NumericString ObjectClassDescription OID
105 OtherMailbox OctetString PostalAddress ProtocolInformation
106 PresentationAddress PrintableString SupportedAlgorithm TelephoneNumber
107 TeletexTerminalIdentifier TelexNumber UTCTime LDAPSyntaxDescription
108 SubstringAssertion NISnetgrouptriple Bootparameter
109 .PD
110 .RE
111 .RE
112 .RE
113 .TP
114 .B concurrency <integer>
115 Specify a desired level of concurrency.  Provided to the underlying
116 thread system as a hint.  The default is not to provdide any hint.
117 .HP
118 .B defaultaccess { none | auth | compare | search | read | write }
119 .RS
120 Specify the default access level to grant requestors when
121 no access directives were provided for the database.
122 The default behavior is to grant 'read' access.  It is
123 recommended that
124 .B access
125 directives be used instead.
126 .RE
127 .TP
128 .B idletimeout <integer>
129 Specify the number of seconds to wait before forcibly closing
130 an idle client connections.  A idletimeout of 0 disables this
131 feature.  The default is 0.
132 .TP
133 .B include <filename>
134 Read additional configuration information from the given file before
135 continuing with the next line of the current file.
136 .TP
137 .B loglevel <integer>
138 Specify the level at which debugging statements and operation 
139 statistics should be syslogged (currently logged to the
140 .BR syslogd (8) 
141 LOG_LOCAL4 facility).  Log levels are additive, and available levels
142 are:
143 .RS
144 .RS
145 .PD 0
146 .TP
147 .B 1
148 trace function calls
149 .TP
150 .B 2
151 debug packet handling
152 .TP
153 .B 4
154 heavy trace debugging
155 .TP
156 .B 8
157 connection management
158 .TP
159 .B 16
160 print out packets sent and received
161 .TP
162 .B 32
163 search filter processing
164 .TP
165 .B 64
166 configuration file processing
167 .TP
168 .B 128
169 access control list processing
170 .TP
171 .B 256
172 stats log connections/operations/results
173 .TP
174 .B 512
175 stats log entries sent
176 .TP
177 .B 1024
178 print communication with shell backends
179 .TP
180 .B 2048
181 entry parsing
182 .PD
183 .RE
184 .RE
185 .HP
186 .B objectclass ( <oid> [NAME <name>] [DESC <description] [OBSOLETE]\
187  [SUP <oids>] [{ ABSTRACT | STRUCTURAL | AUXILIARY }] [MUST <oids>]\
188  [MAY <oids>] )
189 .RS
190 Specify an objectclass using the LDAPv3 syntax defined in RFC 2252.
191 The slapd parser extends the RFC 2252 definition by allowing string
192 forms as well as numeric OIDs to be used for the object class OID.
193 (See the
194 .B
195 objectidentifier
196 description.)  Object classes are "STRUCTURAL" by default.
197 .RE
198 .TP
199 .B objectidentifier <name> { <oid> | <name>[:<suffix>] }
200 Define a string name that equates to the given OID. The string can be used
201 in place of the numeric OID in objectclass and attribute definitions. The
202 name can also be used with a suffix of the form ":xx" in which case the
203 value "oid.xx" will be used.
204 .TP
205 .B pidfile <filename>
206 The ( absolute ) name of a file that will hold the 
207 .B slapd
208 server's process ID ( see
209 .BR getpid (2)
210 ) if started without the debugging command line option.
211 .TP
212 .B password-hash <hash>
213 The <hash> to use for userPassword generation.  One of
214 .BR {SSHA} ,
215 .BR {SHA} ,
216 .BR {SMD5} ,
217 .BR {MD5} ,
218 .BR {CRYPT} ,
219 .BR {KERBEROS} ,
220 .BR {SASL} ,
221 and
222 .BR {UNIX} .
223 The default is
224 .BR {SSHA} .
225 .TP
226 .B referral <url>
227 Specify the referral to pass back when
228 .BR slapd (8)
229 cannot find a local database to handle a request.
230 If specified multiple times, each url is provided.
231 .TP
232 .B sasl-realm <string>
233 Used to specify Cyrus SASL realm.
234 .TP
235 .B sasl-secprops <string>
236 Used to specify Cyrus SASL security properties.
237 .TP
238 .B schemacheck { on | off }
239 Turn schema checking on or off. The default is on.
240 .TP
241 .B sizelimit <integer>
242 Specify the maximum number of entries to return from a search operation.
243 The default size limit is 500.
244 .TP
245 .B sasl-realm <realm>
246 Specify SASL realm.  Default is empty.
247 .TP
248 .B sasl-secprops <props>
249 Cyrus SASL security properties.  Default is "noanonymous,noplain".
250 .TP
251 .B srvtab <filename>
252 Specify the srvtab file in which the kerberos keys necessary for
253 authenticating clients using kerberos can be found. This option is only
254 meaningful if you are using Kerberos authentication.
255 .TP
256 .B timelimit <integer>
257 Specify the maximum number of seconds (in real time)
258 .B slapd
259 will spend answering a search request.  The default time limit is 3600.
260 .SH TLS OPTIONS
261 If
262 .B slapd
263 is build with support for Transport Layer Security, there are more options
264 you can specify.
265 .TP
266 .B TLSCipherSuite <cipher-suite-spec>
267 Permits configuring what ciphers will be accepted and the preference order.
268 <cipher-suite-spec> should be a cipher specification for OpenSSL.  Example:
269
270 TLSCipherSuite HIGH:MEDIUM:+SSLv2
271
272 To check what ciphers a given spec selects, use:
273
274 openssl ciphers -v <cipher-suite-spec>
275 .TP
276 .B TLSCertificateFile <filename>
277 Specifies the file that contains the
278 .B slapd
279 server certificate.
280 .TP
281 .B TLSCertificateKeyFile <filename>
282 Specifies the file that contains the
283 .B slapd
284 server private key that matches the certificate stored in the
285 .B TLSCertificateFile
286 file.  Currently, the private key must not be protected with a password, so
287 it is of critical importance that it is protected carefully. 
288 .SH GENERAL BACKEND OPTIONS
289 Options in this section only apply to the configuration file section
290 for the backend in which they are defined.  They are supported by every
291 type of backend.
292 .TP
293 .B database <databasetype>
294 Mark the beginning of a new database instance definition. <databasetype>
295 should be one of
296 .B ldbm,
297 .B shell,
298 or
299 .B passwd
300 depending on which backend will serve the database.
301 .TP
302 .B lastmod on | off
303 Controls whether
304 .B slapd
305 will automatically maintain the 
306 modifiersName, modifyTimestamp, creatorsName, and 
307 createTimestamp attributes for entries.  By default, lastmod is on.
308 .TP
309 .B readonly on | off
310 This option puts the database into "read-only" mode.  Any attempts to 
311 modify the database will return an "unwilling to perform" error.  By
312 default, readonly is off.
313 .HP
314 .B replica host=<hostname>[:port] bindmethod=simple|sasl
315 .B [binddn=<simple DN>] [credentials=<simple password>]
316 .B [saslmech=<SASL mech>] [authcId=<authentication ID>]
317 .RS
318 Specify a replication site for this database.  Refer to the "OpenLDAP 
319 Administrator's Guide" for detailed information on setting up a replicated
320 .B slapd
321 directory service. A
322 .B bindmethod
323 of
324 .B simple
325 requires the options
326 .B binddn 
327 and
328 .B credentials  
329 and should only be used when adequate security services 
330 (e.g TLS or IPSEC) are in place. A
331 .B bindmethod 
332 of
333 .B sasl 
334 requires the option
335 .B saslmech. 
336 If the 
337 .B mechanism
338 will use Kerberos, a kerberos instance should be given in 
339 .B authcId.
340 .RE
341 .TP
342 .B replogfile <filename>
343 Specify the name of the replication log file to log changes to.  
344 The replication log is typically written by
345 .BR slapd (8)
346 and read by
347 .BR slurpd (8).
348 See
349 .BR slapd.replog (5)
350 for more information.
351 .TP
352 .B rootdn <dn>
353 Specify the distinguished name that is not subject to access control 
354 or administrative limit restrictions for operations on this database.
355 This DN may or may not be associated with an entry.  An empty root
356 DN, the default, specifies no root access is to be granted.
357 .TP
358 .B rootpw <password>
359 Specify a password (or hash of the password) for the rootdn.
360 This option accepts all RFC 2307 userPassword formats known to
361 the server (see 
362 .B password-hash
363 desription) as well as cleartext.
364 .BR slappasswd (8) 
365 may be used to generate a hash of a password.  Cleartext
366 and \fB{CRYPT}\fP passwords are not recommended.  The default
367 is empty imply authentication of the root DN is by other means
368 (e.g. SASL).  Use of SASL is encouraged.
369 .TP
370 .B suffix <dn suffix>
371 Specify the DN suffix of queries that will be passed to this 
372 backend database.  Multiple suffix lines can be given and at least one is 
373 required for each database definition.
374 .TP
375 .B updatedn <dn>
376 This option is only applicable in a slave
377 .B slapd.
378 It specifies the DN allowed to make changes to the replica (typically,
379 this is the DN
380 .BR slurpd (8)
381 binds as when making changes to the replica).
382 .TP
383 .B updateref <url>
384 Specify the referral to pass back when
385 .BR slapd (8)
386 is asked to modify a replicated local database.
387 If specified multiple times, each url is provided.
388 .SH LDBM BACKEND-SPECIFIC OPTIONS
389 Options in this category only apply to the LDBM backend database. That is,
390 they must follow a "database ldbm" line and come before any subsequent
391 "database" lines.  The LDBM backend is a high-performance database that
392 makes extensive use of indexing and caching to speed data access. 
393 .TP
394 .B cachesize <integer>
395 Specify the size in entries of the in-memory cache maintained 
396 by the LDBM backend database instance.  The default is 1000 entries.
397 .TP
398 .B dbcachesize <integer>
399 Specify the size in bytes of the in-memory cache associated 
400 with each open index file. If not supported by the underlying database 
401 method, this option is ignored without comment.  The default is 100000 bytes.
402 .TP
403 .B dbnolocking
404 Specify that no database locking should be performed.  
405 Enabling this option may improve performance at the expense of data security.
406 .B dbnosync
407 Specify that on-disk database contents should not be immediately
408 synchronized with in memory changes.  Enabling this option may improve
409 performance at the expense of data security.
410 .TP
411 .B directory <directory>
412 Specify the directory where the LDBM files containing this database and
413 associated indexes live.  A separate directory must be specified for
414 each database.  The default is
415 .BR LOCALSTATEDIR/openldap-ldbm .
416 .TP
417 .B
418 index {<attrlist>|default} [pres,eq,approx,sub,<special>]
419 Specify the indexes to maintain for the given attribute. If only 
420 an <attr> is given, the indices specified for \fBdefault\fR
421 are maintained.  A number of special index parameters may be
422 specified.
423 The index type
424 .B sub
425 can be decomposed into
426 .BR subinitial ,
427 .BR subany ,\ and
428 .B subfinal
429 indices.
430 The special type
431 .B lang
432 may be specified to allow use of this index by language subtypes.
433 The special type
434 .B autolang
435 may be specified to automatically maintain separate indices for each
436 language subtypes.
437 The special type
438 .B subtypes
439 may be specified to allow use of this index by named subtypes.
440 The special type
441 .B autosubtypes
442 may be specified to automatically maintain separate indices for each
443 other subtypes.
444 .TP
445 .B mode <integer>
446 Specify the file protection mode that newly created database 
447 index files should have.  The default is 0600.
448 .SH SHELL BACKEND-SPECIFIC OPTIONS
449 Options in this category only apply to the SHELL backend database. That is,
450 they must follow a "database shell" line and come before any subsequent
451 "database" lines.  The Shell backend executes external programs to
452 implement operations, and is designed to make it easy to tie an existing
453 database to the
454 .B slapd
455 front-end.
456 .TP
457 .B bind <pathname>
458 .TP
459 .B unbind <pathname>
460 .TP
461 .B search <pathname>
462 .TP
463 .B compare <pathname>
464 .TP
465 .B modify <pathname>
466 .TP
467 .B modrdn <pathname>
468 .TP
469 .B add <pathname>
470 .TP
471 .B delete <pathname>
472 .TP
473 .B abandon <pathname>
474 These options specify the pathname of the command to execute in response 
475 to the given LDAP operation.
476 .LP
477 Note that you need only supply configuration lines for those commands you
478 want the backend to handle. Operations for which a command is not
479 supplied will be refused with an "unwilling to perform" error.
480 .SH PASSWORD BACKEND-SPECIFIC OPTIONS
481 Options in this category only apply to the PASSWD backend database.
482 That is, they must follow a "database passwd" line and come before any
483 subsequent "database" lines.  The PASSWD database serves up the user
484 account information listed in the system
485 .BR passwd (5)
486 file.
487 .TP
488 .B file <filename>
489 Specifies an alternate passwd file to use.  The default is
490 .B /etc/passwd.
491 .SH EXAMPLE
492 "OpenLDAP Administrator's Guide" contains an annotated
493 example of a configuration file.
494 .SH FILES
495 ETCDIR/slapd.conf
496 .SH SEE ALSO
497 .BR ldap (3),
498 .BR slapd.replog (5),
499 .BR locale (5),
500 .BR passwd (5),
501 .BR slapd (8),
502 .BR slapadd (8),
503 .BR slapcat (8),
504 .BR slapindex (8),
505 .BR slappassword (8),
506 .BR slurpd (8),
507 .LP
508 "OpenLDAP Administrator's Guide"
509 .SH ACKNOWLEDGEMENTS
510 .B      OpenLDAP
511 is developed and maintained by The OpenLDAP Project (http://www.openldap.org/).
512 .B      OpenLDAP
513 is derived from University of Michigan LDAP 3.3 Release.