]> git.sur5r.net Git - openldap/blob - doc/man/man5/slapd.conf.5
e696f529b2c106b440a427b111c44414a67f6058
[openldap] / doc / man / man5 / slapd.conf.5
1 .TH SLAPD.CONF 5 "RELEASEDATE" "OpenLDAP LDVERSION"
2 .\" Copyright 1998-2003 The OpenLDAP Foundation All Rights Reserved.
3 .\" Copying restrictions apply.  See COPYRIGHT/LICENSE.
4 .\" $OpenLDAP$
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, and General Database
60 Options.  Backend-specific options are discussed in the
61 .B slapd-<backend>(5)
62 manual pages.  Refer to the "OpenLDAP Administrator's Guide" for more
63 details on the slapd configuration 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
74 .BR slapd.access (5)
75 and the "OpenLDAP's Administrator's Guide" for details.
76 .TP
77 .B allow <features>
78 Specify a set of features (separated by white space) to
79 allow (default none).
80 .B bind_v2
81 allows acceptance of LDAPv2 bind requests.  Note that
82 .BR slapd (8)
83 does not truely implement LDAPv2 (RFC 1777), now Historic (RFC 3494).
84 .B bind_anon_cred
85 allows anonymous bind when credentials are not empty (e.g.
86 when DN is empty).
87 .B bind_anon_dn
88 allows unauthenticated (anonymous) bind when DN is not empty.
89 .B update_anon
90 allow unauthenticated (anonymous) update operations to be processed
91 (subject to access controls and other administrative limits).
92 .TP
93 .B argsfile <filename>
94 The ( absolute ) name of a file that will hold the 
95 .B slapd
96 server's command line options
97 if started without the debugging command line option.
98 .TP
99 .B attributeoptions [option-name]...
100 Define tagging attribute options or option tag/range prefixes.
101 Options must not end with `-', prefixes must end with `-'.
102 The `lang-' prefix is predefined.
103 If you use the
104 .B attributeoptions
105 directive, `lang-' will no longer be defined and you must specify it
106 explicitly if you want it defined.
107
108 An attribute description with a tagging option is a subtype of that
109 attribute description without the option.
110 Except for that, options defined this way have no special semantics.
111 Prefixes defined this way work like the `lang-' options:
112 They define a prefix for tagging options starting with the prefix.
113 That is, if you define the prefix `x-foo-', you can use the option
114 `x-foo-bar'.
115 Furthermore, in a search or compare, a prefix or range name (with
116 a trailing `-') matches all options starting with that name, as well
117 as the option with the range name sans the trailing `-'.
118 That is, `x-foo-bar-' matches `x-foo-bar' and `x-foo-bar-baz'.
119
120 RFC2251 reserves options beginning with `x-' for private experiments.
121 Other options should be registered with IANA, see RFC3383 section 3.4.
122 OpenLDAP also has the `binary' option built in, but this is a transfer
123 option, not a tagging option.
124 .HP
125 .hy 0
126 .B attributetype "(\ <oid> [NAME\ <name>] [OBSOLETE]\
127  [DESC\ <description>]\
128  [SUP\ <oid>] [EQUALITY\ <oid>] [ORDERING\ <oid>]\
129  [SUBSTR\ <oid>] [SYNTAX\ <oidlen>] [SINGLE\-VALUE] [COLLECTIVE]\
130  [NO\-USER\-MODIFICATION] [USAGE\ <attributeUsage>]\ )"
131 .RS
132 Specify an attribute type using the LDAPv3 syntax defined in RFC 2252.
133 The slapd parser extends the RFC 2252 definition by allowing string
134 forms as well as numeric OIDs to be used for the attribute OID and
135 attribute syntax OID.
136 (See the
137 .B objectidentifier
138 description.) 
139 .RE
140 .TP
141 .B concurrency <integer>
142 Specify a desired level of concurrency.  Provided to the underlying
143 thread system as a hint.  The default is not to provide any hint.
144 .TP
145 .B conn_max_pending <integer>
146 Specify the maximum number of pending requests for an anonymous session.
147 If requests are submitted faster than the server can process them, they
148 will be queued up to this limit. If the limit is exceeded, the session
149 is closed. The default is 100.
150 .TP
151 .B conn_max_pending_auth <integer>
152 Specify the maximum number of pending requests for an authenticated session.
153 The default is 1000.
154 .\".TP
155 .\".B debug <subsys> <level>
156 .\"Specify a logging level for a particular subsystem.  The subsystems include
157 .\".B global
158 .\"a global level for all subsystems,
159 .\".B acl
160 .\"the ACL engine,
161 .\".B backend
162 .\"the backend databases,
163 .\".B cache
164 .\"the entry cache manager,
165 .\".B config
166 .\"the config file reader,
167 .\".B connection
168 .\"the connection manager,
169 .\".B cyrus
170 .\"the Cyrus SASL library interface,
171 .\".B filter
172 .\"the search filter processor,
173 .\".B getdn
174 .\"the DN normalization library,
175 .\".B index
176 .\"the database indexer,
177 .\".B liblber
178 .\"the ASN.1 BER library,
179 .\".B module
180 .\"the dynamic module loader,
181 .\".B operation
182 .\"the LDAP operation processors,
183 .\".B sasl
184 .\"the SASL authentication subsystem,
185 .\".B schema
186 .\"the schema processor, and
187 .\".B tls
188 .\"the TLS library interface. This is not an exhaustive list; there are many
189 .\"other subsystems and more are added over time.
190 .\"
191 .\"The levels are, in order of decreasing priority:
192 .\".B emergency, alert, critical, error, warning, notice, information, entry,
193 .\".B args, results, detail1, detail2
194 .\"An integer may be used instead, with 0 corresponding to
195 .\".B emergency
196 .\"up to 11 for
197 .\".BR detail2 .
198 .\"The
199 .\".B entry
200 .\"level logs function entry points,
201 .\".B args
202 .\"adds function call parameters, and
203 .\".B results
204 .\"adds the function results to the logs.
205 .\"The
206 .\".B detail1
207 .\"and
208 .\".B detail2
209 .\"levels add even more low level detail from individual functions.
210 .TP
211 .B defaultsearchbase <dn>
212 Specify a default search base to use when client submits a
213 non-base search request with an empty base DN.
214 .TP
215 .B disallow <features>
216 Specify a set of features (separated by white space) to
217 disallow (default none).
218 .B bind_anon
219 disables acceptance of anonymous bind requests.
220 .B bind_simple
221 disables simple (bind) authentication.
222 .B bind_simple_unprotected
223 disables simple (bind) authentication when confidentiality
224 protection (e.g. TLS) is not in place.  The
225 .B security
226 directive's
227 .B simple_bind
228 option provides fine grain control over the confidentiality
229 protection required for simple bind.
230 .B bind_krbv4
231 disables Kerberos V4 (bind) authentication.
232 .B tls_2_anon
233 disables Start TLS from forcing session to anonymous status (see also
234 .BR tls_authc ).
235 .B tls_authc
236 disables StartTLS if authenticated (see also
237 .BR tls_2_anon ).
238 .TP
239 .B gentlehup { on | off }
240 A SIGHUP signal will only cause a 'gentle' shutdown-attempt:
241 .B Slapd
242 will stop listening for new connections, but will not close the
243 connections to the current clients.  Future write operations return
244 unwilling-to-perform, though.  Slapd terminates when all clients
245 have closed their connections (if they ever do), or \- as before \-
246 if it receives a SIGTERM signal.  This can be useful if you wish to
247 terminate the server and start a new
248 .B slapd
249 server
250 .B with another database,
251 without disrupting the currently active clients.
252 The default is off.  You may wish to use
253 .B idletimeout
254 along with this option.
255 .TP
256 .B idletimeout <integer>
257 Specify the number of seconds to wait before forcibly closing
258 an idle client connection.  A idletimeout of 0 disables this
259 feature.  The default is 0.
260 .TP
261 .B include <filename>
262 Read additional configuration information from the given file before
263 continuing with the next line of the current file.
264 .TP
265 .B limits <who> <limit> [<limit> [...]]
266 Specify time and size limits based on who initiated an operation.
267 The argument
268 .B who
269 can be any of
270 .RS
271 .RS
272 .TP
273 anonymous | users | [dn[.<style>]=]<pattern>
274
275 .RE
276 with
277 .RS
278 .TP
279 <style> ::= exact | base | one | subtree | children | regex | anonymous
280
281 .RE
282 .B Anonymous
283 is hit when a search is performed without prior binding;
284 .B users
285 is hit when a search is performed by a successfully bound user;
286 otherwise a
287 .B regex
288 dn pattern is assumed unless otherwise specified by qualifying 
289 the (optional) key string
290 .B dn
291 with 
292 .B exact
293 or
294 .B base
295 (which are synonims), to require an exact match; with
296 .BR one, 
297 to require exactly one level of depth match; with
298 .BR subtree,
299 to allow any level of depth match, including the exact match; with
300 .BR children,
301 to allow any level of depth match, not including the exact match;
302 .BR regex
303 explicitly requires the (default) match based on regular expression
304 pattern, as detailed in
305 .BR regex (7).
306 Finally,
307 .B anonymous
308 matches unbound operations; the 
309 .B pattern
310 field is ignored.
311 The same behavior is obtained by using the 
312 .B anonymous
313 form of the
314 .B who
315 clause.
316
317 The currently supported limits are 
318 .B size
319 and 
320 .BR time.
321
322 The syntax for time limits is 
323 .BR time[.{soft|hard}]=<integer> ,
324 where 
325 .BR integer
326 is the number of seconds slapd will spend answering a search request.
327 If no time limit is explicitly requested by the client, the 
328 .BR soft
329 limit is used; if the requested time limit exceedes the
330 .BR hard
331 limit, an "Administrative limit exceeded" is returned.
332 If the
333 .BR hard
334 limit is set to 0 or to the keyword "soft", the soft limit is used 
335 in either case; if it is set to -1 or to the keyword "none", 
336 no hard limit is enforced.
337 Explicit requests for time limits smaller or equal to the
338 .BR hard 
339 limit are honored.
340 If no flag is set, the value is assigned to the 
341 .BR soft 
342 limit, and the
343 .BR hard
344 limit is set to zero, to preserve the original behavior.
345
346 The syntax for size limits is
347 .BR size[.{soft|hard|unchecked}]=<integer> ,
348 where
349 .BR integer
350 is the maximum number of entries slapd will return answering a search 
351 request.
352 If no size limit is explicitly requested by the client, the
353 .BR soft
354 limit is used; if the requested size limit exceedes the
355 .BR hard
356 limit, an "Administrative limit exceeded" is returned.
357 If the 
358 .BR hard
359 limit is set to 0 or to the keyword "soft", the soft limit is used 
360 in either case; if it is set to -1 or to the keyword "none", 
361 no hard limit is enforced.
362 Explicit requests for size limits smaller or equal to the
363 .BR hard
364 limit are honored.
365 The
366 .BR unchecked
367 flag sets a limit on the number of candidates a search request is allowed
368 to examine.
369 If the selected candidates exceed the 
370 .BR unchecked
371 limit, the search will abort with "Unwilling to perform".
372 If it is set to -1 or to the keyword "none", no limit is applied (the default).
373 If no flag is set, the value is assigned to the
374 .BR soft 
375 limit, and the
376 .BR hard
377 limit is set to zero, to preserve the original behavior.
378
379 In case of no match, the global limits are used.
380 The default values are the same of
381 .BR sizelimit
382 and
383 .BR timelimit ;
384 no limit is set on 
385 .BR unchecked .
386
387 If 
388 .B pagedResults
389 control is defined, additional size limits may be enforced; the syntax is
390 .BR size.pr={<integer>|noEstimate} ,
391 where
392 .BR integer
393 is the max page size if no explicit limit is set; the keyword
394 .BR noEstimate
395 inhibits the server to return an estimate of the total number
396 of entries that will be returned.
397 .RE
398 .\".TP
399 .\".B logfile <filename>
400 .\"Specify a file for recording debug log messages. By default these messages
401 .\"only go to stderr and are not recorded anywhere else. Specifying a logfile
402 .\"copies messages to both stderr and the logfile.
403 .TP
404 .B loglevel <integer>
405 Specify the level at which debugging statements and operation 
406 statistics should be syslogged (currently logged to the
407 .BR syslogd (8) 
408 LOG_LOCAL4 facility).  Log levels are additive, and available levels
409 are:
410 .RS
411 .RS
412 .PD 0
413 .TP
414 .B 1
415 trace function calls
416 .TP
417 .B 2
418 debug packet handling
419 .TP
420 .B 4
421 heavy trace debugging
422 .TP
423 .B 8
424 connection management
425 .TP
426 .B 16
427 print out packets sent and received
428 .TP
429 .B 32
430 search filter processing
431 .TP
432 .B 64
433 configuration file processing
434 .TP
435 .B 128
436 access control list processing
437 .TP
438 .B 256
439 stats log connections/operations/results
440 .TP
441 .B 512
442 stats log entries sent
443 .TP
444 .B 1024
445 print communication with shell backends
446 .TP
447 .B 2048
448 entry parsing
449 .PD
450 .RE
451 .RE
452 .TP
453 .B moduleload <filename>
454 Specify the name of a dynamically loadable module to load. The filename
455 may be an absolute path name or a simple filename. Non-absolute names
456 are searched for in the directories specified by the
457 .B modulepath
458 option. This option and the
459 .B modulepath
460 option are only usable if slapd was compiled with --enable-modules.
461 .TP
462 .B modulepath <pathspec>
463 Specify a list of directories to search for loadable modules. Typically
464 the path is colon-separated but this depends on the operating system.
465 .HP
466 .B objectclass "( <oid> [NAME <name>] [DESC <description] [OBSOLETE]\
467  [SUP <oids>] [{ ABSTRACT | STRUCTURAL | AUXILIARY }] [MUST <oids>]\
468  [MAY <oids>] )"
469 .RS
470 Specify an objectclass using the LDAPv3 syntax defined in RFC 2252.
471 The slapd parser extends the RFC 2252 definition by allowing string
472 forms as well as numeric OIDs to be used for the object class OID.
473 (See the
474 .B
475 objectidentifier
476 description.)  Object classes are "STRUCTURAL" by default.
477 .RE
478 .TP
479 .B objectidentifier <name> "{ <oid> | <name>[:<suffix>] }"
480 Define a string name that equates to the given OID. The string can be used
481 in place of the numeric OID in objectclass and attribute definitions. The
482 name can also be used with a suffix of the form ":xx" in which case the
483 value "oid.xx" will be used.
484 .TP
485 .B password-hash <hash>
486 This option sets the hash to be used in generation of user
487 passwords, stored in userPassword, during processing of
488 LDAP Password Modify Extended Operations (RFC 3052).
489 The <hash> must be one of
490 .BR {SSHA} ,
491 .BR {SHA} ,
492 .BR {SMD5} ,
493 .BR {MD5} ,
494 .BR {CRYPT} ,
495 and
496 .BR {CLEARTEXT} .
497 The default is
498 .BR {SSHA} .
499
500 .B {SHA}
501 and
502 .B {SSHA}
503 use the SHA-1 algorithm (FIPS 160-1), the latter with a seed.
504
505 .B {MD5}
506 and
507 .B {SMD5}
508 use the MD5 algorithm (RFC 1321), the latter with a seed.
509
510 .B {CRYPT}
511 uses the
512 .BR crypt (3).
513
514 .B {CLEARTEXT}
515 indicates that the new password should be
516 added to userPassword as clear text.
517
518 Note that this option does not alter the normal user applications
519 handling of userPassword during LDAP Add, Modify, or other LDAP operations.
520 .TP
521 .B password\-crypt\-salt\-format <format>
522 Specify the format of the salt passed to
523 .BR crypt (3)
524 when generating {CRYPT} passwords (see
525 .BR password\-hash )
526 during processing of LDAP Password Modify Extended Operations (RFC 3062).
527
528 This string needs to be in
529 .BR sprintf (3)
530 format and may include one (and only one) %s conversion.
531 This conversion will be substituted with a string random
532 characters from [A\-Za\-z0\-9./].  For example, "%.2s"
533 provides a two character salt and "$1$%.8s" tells some
534 versions of crypt(3) to use an MD5 algorithm and provides
535 8 random characters of salt.  The default is "%s", which
536 provides 31 characters of salt.
537 .TP
538 .B pidfile <filename>
539 The ( absolute ) name of a file that will hold the 
540 .B slapd
541 server's process ID ( see
542 .BR getpid (2)
543 ) if started without the debugging command line option.
544 .TP
545 .B referral <url>
546 Specify the referral to pass back when
547 .BR slapd (8)
548 cannot find a local database to handle a request.
549 If specified multiple times, each url is provided.
550 .TP
551 .B require <conditions>
552 Specify a set of conditions (separated by white space) to
553 require (default none).
554 The directive may be specified globally and/or per-database.
555 .B bind
556 requires bind operation prior to directory operations.
557 .B LDAPv3
558 requires session to be using LDAP version 3.
559 .B authc
560 requires authentication prior to directory operations.
561 .B SASL
562 requires SASL authentication prior to directory operations.
563 .B strong
564 requires strong authentication prior to directory operations.
565 The strong keyword allows protected "simple" authentication
566 as well as SASL authentication.
567 .B none
568 may be used to require no conditions (useful for clearly globally
569 set conditions within a particular database).
570 .TP
571 .B reverse-lookup on | off
572 Enable/disable client name unverified reverse lookup (default is 
573 .BR off 
574 if compiled with --enable-rlookups).
575 .TP
576 .B rootDSE <file>
577 Specify the name of an LDIF(5) file containing user defined attributes
578 for the root DSE.  These attributes are returned in addition to the
579 attributes normally produced by slapd.
580 .TP
581 .B sasl-authz-policy <policy>
582 Used to specify which rules to use for SASL Proxy Authorization. Proxy
583 authorization allows a client to authenticate to the server using one
584 user's credentials, but specify a different identity to use for authorization
585 and access control purposes. It essentially allows user A to login as user
586 B, using user A's password.
587 The
588 .B none
589 flag disables proxy authorization. This is the default setting.
590 The
591 .B from
592 flag will use rules in the
593 .I saslAuthzFrom
594 attribute of the authorization DN.
595 The
596 .B to
597 flag will use rules in the
598 .I saslAuthzTo
599 attribute of the authentication DN.
600 The
601 .B both
602 flag will allow both of the above. The rules are simply regular expressions
603 specifying which DNs are allowed to perform proxy authorization. The
604 .I saslAuthzFrom
605 attribute in an entry specifies which other users
606 are allowed to proxy login to this entry. The
607 .I saslAuthzTo
608 attribute in
609 an entry specifies which other users this user can authorize as.  Use of
610 .I saslAuthzTo
611 rules can be easily
612 abused if users are allowed to write arbitrary values to this attribute.
613 In general the
614 .I saslAuthzTo
615 attribute must be protected with ACLs such that
616 only privileged users can modify it.
617 .TP
618 .B sasl-host <fqdn>
619 Used to specify the fully qualified domain name used for SASL processing.
620 .TP
621 .B sasl-realm <realm>
622 Specify SASL realm.  Default is empty.
623 .TP
624 .B sasl-regexp <match> <replace>
625 Used by the SASL authorization mechanism to convert a SASL authenticated 
626 username to an LDAP DN. When an authorization request is received, the SASL 
627 .B USERNAME, REALM, 
628 and
629 .B MECHANISM
630 are taken, when available, and combined into a SASL name of the 
631 form
632 .RS
633 .RS
634 .TP
635 .B uid=<username>[,cn=<realm>],cn=<mechanism>,cn=auth
636
637 .RE
638 This SASL name is then compared against the
639 .B match
640 regular expression, and if the match is successful, the SASL name is
641 replaced with the
642 .B replace
643 string. If there are wildcard strings in the 
644 .B match
645 regular expression that are enclosed in parenthesis, e.g. 
646 .RS
647 .RS
648 .TP
649 .B uid=(.*),cn=.*
650
651 .RE
652 .RE
653 then the portion of the SASL name that matched the wildcard will be stored
654 in the numbered placeholder variable $1. If there are other wildcard strings
655 in parenthesis, the matching strings will be in $2, $3, etc. up to $9. The 
656 placeholders can then be used in the 
657 .B replace
658 string, e.g. 
659 .RS
660 .RS
661 .TP
662 .B cn=$1,ou=Accounts,dc=$2,dc=$4. 
663
664 .RE
665 .RE
666 The replaced SASL name can be either a DN or an LDAP URI. If the latter, the slapd
667 server will use the URI to search its own database, and if the search returns 
668 exactly one entry, the SASL name is replaced by the DN of that entry.
669 Multiple 
670 .B sasl-regexp 
671 options can be given in the configuration file to allow for multiple matching 
672 and replacement patterns. The matching patterns are checked in the order they 
673 appear in the file, stopping at the first successful match.
674
675 .\".B Caution:
676 .\"Because the plus sign + is a character recognized by the regular expression engine,
677 .\"and it will appear in SASL names that include a REALM, be careful to escape the
678 .\"plus sign with a backslash \\+ to remove the character's special meaning.
679 .RE
680 .TP
681 .B sasl-secprops <properties>
682 Used to specify Cyrus SASL security properties.
683 The
684 .B none
685 flag (without any other properities) causes the flag properites
686 default, "noanonymous,noplain", to be cleared.
687 The
688 .B noplain
689 flag disables mechanisms susceptible to simple passive attacks.
690 The
691 .B noactive
692 flag disables mechanisms susceptible to active attacks.
693 The
694 .B nodict
695 flag disables mechanisms susceptible to passive dictionary attacks.
696 The
697 .B noanonymous
698 flag disables mechanisms which support anonymous login.
699 The
700 .B forwardsec
701 flag require forward secrecy between sessions.
702 The
703 .B passcred
704 require mechanisms which pass client credentials (and allow
705 mechanisms which can pass credentials to do so).
706 The
707 .B minssf=<factor> 
708 property specifies the minimum acceptable
709 .I security strength factor
710 as an integer approximate to effective key length used for
711 encryption.  0 (zero) implies no protection, 1 implies integrity
712 protection only, 56 allows DES or other weak ciphers, 112
713 allows triple DES and other strong ciphers, 128 allows RC4,
714 Blowfish and other modern strong ciphers.  The default is 0.
715 The
716 .B maxssf=<factor> 
717 property specifies the maximum acceptable
718 .I security strength factor
719 as an integer (see minssf description).  The default is INT_MAX.
720 The
721 .B maxbufsize=<size> 
722 property specifies the maximum security layer receive buffer
723 size allowed.  0 disables security layers.  The default is 65536.
724 .TP
725 .B schemadn <dn>
726 Specify the distinguished name for the subschema subentry that
727 controls the entries on this server.  The default is "cn=Subschema".
728 .TP
729 .B security <factors>
730 Specify a set of factors (separated by white space) to require.
731 An integer value is associated with each factor and is roughly
732 equivalent of the encryption key length to require.  A value
733 of 112 is equivalent to 3DES, 128 to Blowfish, etc..
734 The directive may be specified globally and/or per-database.
735 .B ssf=<n>
736 specifies the overall security strength factor.
737 .B transport=<n>
738 specifies the transport security strength factor.
739 .B tls=<n>
740 specifies the TLS security strength factor.
741 .B sasl=<n>
742 specifies the SASL security strength factor.
743 .B update_ssf=<n>
744 specifies the overall security strength factor to require for
745 directory updates.
746 .B update_transport=<n>
747 specifies the transport security strength factor to require for
748 directory updates.
749 .B update_tls=<n>
750 specifies the TLS security strength factor to require for
751 directory updates.
752 .B update_sasl=<n>
753 specifies the SASL security strength factor to require for
754 directory updates.
755 .B simple_bind=<n>
756 specifies the security strength factor required for
757 .I simple
758 username/password authentication.
759 Note that the
760 .B transport
761 factor is measure of security provided by the underlying transport,
762 e.g. ldapi:// (and eventually IPSEC).  It is not normally used.
763 .TP
764 .B sizelimit {<integer>|unlimited}
765 .TP
766 .B sizelimit size[.{soft|hard|unchecked}]=<integer> [...]
767 Specify the maximum number of entries to return from a search operation.
768 The default size limit is 500.
769 Use
770 .B -1
771 or 
772 .B unlimited
773 to specify no limits.
774 The second format allows a fine grain setting of the size limits.
775 Extra args can be added on the same line.
776 See
777 .BR limits
778 for an explanation of the different flags.
779 .TP
780 .B sockbuf_max_incoming <integer>
781 Specify the maximum incoming LDAP PDU size for anonymous sessions.
782 The default is 262143.
783 .TP
784 .B sockbuf_max_incoming_auth <integer>
785 Specify the maximum incoming LDAP PDU size for authenticated sessions.
786 The default is 4194303.
787 .TP
788 .B srvtab <filename>
789 Specify the srvtab file in which the kerberos keys necessary for
790 authenticating clients using kerberos can be found. This option is only
791 meaningful if you are using Kerberos authentication.
792 .TP
793 .B threads <integer>
794 Specify the maximum size of the primary thread pool.
795 The default is 16.
796 .TP
797 .B timelimit {<integer>|unlimited}
798 .TP
799 .B timelimit time[.{soft|hard}]=<integer> [...]
800 Specify the maximum number of seconds (in real time)
801 .B slapd
802 will spend answering a search request.  The default time limit is 3600.
803 Use
804 .B -1
805 or 
806 .B unlimited
807 to specify no limits.
808 The second format allows a fine grain setting of the time limits.
809 Extra args can be added on the same line.
810 See
811 .BR limits
812 for an explanation of the different flags.
813 .TP
814 .B ucdata-path <path>
815 Specify the path to the directory containing the Unicode character
816 tables. The default path is LOCALSTATEDIR/ucdata.
817 .SH TLS OPTIONS
818 If
819 .B slapd
820 is built with support for Transport Layer Security, there are more options
821 you can specify.
822 .TP
823 .B TLSCipherSuite <cipher-suite-spec>
824 Permits configuring what ciphers will be accepted and the preference order.
825 <cipher-suite-spec> should be a cipher specification for OpenSSL.  Example:
826
827 TLSCipherSuite HIGH:MEDIUM:+SSLv2
828
829 To check what ciphers a given spec selects, use:
830
831 openssl ciphers -v <cipher-suite-spec>
832 .TP
833 .B TLSCACertificateFile <filename>
834 Specifies the file that contains certificates for all of the Certificate
835 Authorities that
836 .B slapd
837 will recognize.
838 .TP
839 .B TLSCACertificatePath <path>
840 Specifies the path of a directory that contains Certificate Authority
841 certificates in separate individual files. Usually only one of this
842 or the TLSCACertificateFile is used.
843 .TP
844 .B TLSCertificateFile <filename>
845 Specifies the file that contains the
846 .B slapd
847 server certificate.
848 .TP
849 .B TLSCertificateKeyFile <filename>
850 Specifies the file that contains the
851 .B slapd
852 server private key that matches the certificate stored in the
853 .B TLSCertificateFile
854 file.  Currently, the private key must not be protected with a password, so
855 it is of critical importance that it is protected carefully. 
856 .TP
857 .B TLSRandFile <filename>
858 Specifies the file to obtain random bits from when /dev/[u]random
859 is not available.  Generally set to the name of the EGD/PRNGD socket.
860 The environment variable RANDFILE can also be used to specify the filename.
861 .TP
862 .B TLSVerifyClient <level>
863 Specifies what checks to perform on client certificates in an
864 incoming TLS session, if any.
865 The
866 .B <level>
867 can be specified as one of the following keywords:
868 .RS
869 .TP
870 .B never
871 This is the default.
872 .B slapd
873 will not ask the client for a certificate.
874 .TP
875 .B allow
876 The client certificate is requested.  If no certificate is provided,
877 the session proceeds normally.  If a bad certificate is provided,
878 it will be ignored and the session proceeds normally.
879 .TP
880 .B try
881 The client certificate is requested.  If no certificate is provided,
882 the session proceeds normally.  If a bad certificate is provided,
883 the session is immediately terminated.
884 .TP
885 .B demand | hard | true
886 These keywords are all equivalent, for compatibility reasons.
887 The client certificate is requested.  If no certificate is provided,
888 or a bad certificate is provided, the session is immediately terminated.
889
890 Note that a valid client certificate is required in order to use the
891 SASL EXTERNAL authentication mechanism with a TLS session.  As such,
892 a non-default
893 .B TLSVerifyClient
894 setting must be chosen to enable SASL EXTERNAL authentication.
895 .RE
896 .SH GENERAL BACKEND OPTIONS
897 Options in this section only apply to the configuration file section
898 for the specified backend.  They are supported by every
899 type of backend.
900 .TP
901 .B backend <databasetype>
902 Mark the beginning of a backend definition. <databasetype>
903 should be one of
904 .B bdb,
905 .B dnssrv,
906 .B ldap,
907 .B ldbm,
908 .B meta,
909 .B monitor,
910 .B null,
911 .B passwd,
912 .B perl,
913 .B shell,
914 .B sql,
915 or
916 .B tcl,
917 depending on which backend will serve the database.
918
919 .SH GENERAL DATABASE OPTIONS
920 Options in this section only apply to the configuration file section
921 for the database in which they are defined.  They are supported by every
922 type of backend.  Note that the
923 .B database
924 and at least one
925 .B suffix
926 option are mandatory for each database.
927 .TP
928 .B database <databasetype>
929 Mark the beginning of a new database instance definition. <databasetype>
930 should be one of
931 .B bdb,
932 .B dnssrv,
933 .B ldap,
934 .B ldbm,
935 .B meta,
936 .B monitor,
937 .B null,
938 .B passwd,
939 .B perl,
940 .B shell,
941 .B sql,
942 or
943 .B tcl,
944 depending on which backend will serve the database.
945 .TP
946 .B lastmod on | off
947 Controls whether
948 .B slapd
949 will automatically maintain the 
950 modifiersName, modifyTimestamp, creatorsName, and 
951 createTimestamp attributes for entries.  By default, lastmod is on.
952 .TP
953 .B maxderefdepth <depth>
954 Specifies the maximum number of aliases to dereference when trying to
955 resolve an entry, used to avoid inifinite alias loops. The default is 1.
956 .TP
957 .B readonly on | off
958 This option puts the database into "read-only" mode.  Any attempts to 
959 modify the database will return an "unwilling to perform" error.  By
960 default, readonly is off.
961 .HP
962 .B replica host=<hostname>[:port] [tls=yes|critical]
963 .B [suffix=<suffix> [...]]
964 .B bindmethod=simple|sasl [binddn=<simple DN>] [credentials=<simple password>]
965 .B [saslmech=<SASL mech>] [secprops=<properties>] [realm=<realm>]
966 .B [authcId=<authentication ID>] [authzId=<authorization ID>]
967 .B [attr[!]=<attr list>]
968 .RS
969 Specify a replication site for this database.  Refer to the "OpenLDAP 
970 Administrator's Guide" for detailed information on setting up a replicated
971 .B slapd
972 directory service. Zero or more
973 .B suffix
974 instances can be used to select the subtrees that will be replicated
975 (defaults to all the database). A
976 .B bindmethod
977 of
978 .B simple
979 requires the options
980 .B binddn 
981 and
982 .B credentials  
983 and should only be used when adequate security services 
984 (e.g TLS or IPSEC) are in place. A
985 .B bindmethod 
986 of
987 .B sasl 
988 requires the option
989 .B saslmech. 
990 Specific security properties (as with the
991 .B sasl-secprops
992 keyword above) for a SASL bind can be set with the
993 .B secprops
994 option. A non-default SASL realm can be set with the
995 .B realm
996 option.
997 If the 
998 .B mechanism
999 will use Kerberos, a kerberos instance should be given in 
1000 .B authcId.
1001 An
1002 .B attr list
1003 can be given after the 
1004 .B attr
1005 keyword to allow the selective replication of the listed attributes only;
1006 if the optional 
1007 .B !
1008 mark is used, the list is considered exclusive, i.e. the listed attributes
1009 are not replicated.
1010 If an objectClass is listed, all the related attributes
1011 are (are not) replicated.
1012 .RE
1013 .TP
1014 .B replogfile <filename>
1015 Specify the name of the replication log file to log changes to.  
1016 The replication log is typically written by
1017 .BR slapd (8)
1018 and read by
1019 .BR slurpd (8).
1020 See
1021 .BR slapd.replog (5)
1022 for more information.  The specified file should be located
1023 in a directory with limited read/write/execute access as the replication
1024 logs may contain sensitive information.
1025 .TP
1026 .B rootdn <dn>
1027 Specify the distinguished name that is not subject to access control 
1028 or administrative limit restrictions for operations on this database.
1029 This DN may or may not be associated with an entry.  An empty root
1030 DN (the default) specifies no root access is to be granted.  It is
1031 recommended that the rootdn only be specified when needed (such as
1032 when initially populating a database).  If the rootdn is within
1033 a namingContext (suffix) of the database, a simple bind password
1034 may also be provided using the
1035 .B rootpw
1036 directive.
1037 .TP
1038 .B rootpw <password>
1039 Specify a password (or hash of the password) for the rootdn.  The
1040 password can only be set if the rootdn is within the namingContext
1041 (suffix) of the database.
1042 This option accepts all RFC 2307 userPassword formats known to
1043 the server (see 
1044 .B password-hash
1045 desription) as well as cleartext.
1046 .BR slappasswd (8) 
1047 may be used to generate a hash of a password.  Cleartext
1048 and \fB{CRYPT}\fP passwords are not recommended.  If empty
1049 (the default), authentication of the root DN is by other means
1050 (e.g. SASL).  Use of SASL is encouraged.
1051 .TP
1052 .B suffix <dn suffix>
1053 Specify the DN suffix of queries that will be passed to this 
1054 backend database.  Multiple suffix lines can be given and at least one is 
1055 required for each database definition.
1056 If the suffix of one database is "inside" that of another, the database
1057 with the inner suffix must come first in the configuration file.
1058 .TP
1059 .B subordinate
1060 Specify that the current backend database is a subordinate of another
1061 backend database. A subordinate database may have only one suffix. This
1062 option may be used to glue multiple databases into a single namingContext.
1063 If the suffix of the current database is within the namingContext of a
1064 superior database, searches against the superior database will be
1065 propagated to the subordinate as well. All of the databases
1066 associated with a single namingContext should have identical rootdns.
1067 Behavior of other LDAP operations is unaffected by this setting. In
1068 particular, it is not possible to use moddn to move an entry from
1069 one subordinate to another subordinate within the namingContext.
1070 .TP
1071 .B updatedn <dn>
1072 This option is only applicable in a slave
1073 .B slapd.
1074 It specifies the DN allowed to make changes to the replica (typically,
1075 this is the DN
1076 .BR slurpd (8)
1077 binds as when making changes to the replica).
1078 .TP
1079 .B updateref <url>
1080 Specify the referral to pass back when
1081 .BR slapd (8)
1082 is asked to modify a replicated local database.
1083 If specified multiple times, each url is provided.
1084 .SH DATABASE-SPECIFIC OPTIONS
1085 Each database may allow specific configuration options; they are
1086 documented separately in the
1087 .BR slapd-<backend> (5)
1088 manual pages.
1089 .SH EXAMPLES
1090 .LP
1091 Here is a short example of a configuration file:
1092 .LP
1093 .RS
1094 .nf
1095 include   SYSCONFDIR/schema/core.schema
1096 pidfile   LOCALSTATEDIR/slapd.pid
1097
1098 # Subtypes of "name" (e.g. "cn" and "ou") with the
1099 # option ";x-hidden" can be searched for/compared,
1100 # but are not shown.  See \fBslapd.access\fP(5).
1101 attributeoptions x-hidden lang-
1102 access to attr=name;x-hidden by * =cs
1103
1104 database  bdb
1105 suffix    "dc=our-domain,dc=com"
1106 # The database directory MUST exist prior to
1107 # running slapd AND should only be accessible
1108 # by the slapd/tools. Mode 700 recommended.
1109 directory LOCALSTATEDIR/openldap-data
1110 # Indices to maintain
1111 index     objectClass  eq
1112 index     cn,sn,mail   pres,eq,approx,sub
1113
1114 # We serve small clients that do not handle referrals,
1115 # so handle remote lookups on their behalf.
1116 database  ldap
1117 suffix    ""
1118 uri       ldap://ldap.some-server.com/
1119 lastmod   off
1120 .fi
1121 .RE
1122 .LP
1123 "OpenLDAP Administrator's Guide" contains a longer annotated
1124 example of a configuration file.
1125 The original ETCDIR/slapd.conf is another example.
1126 .SH FILES
1127 .TP
1128 ETCDIR/slapd.conf
1129 default slapd configuration file
1130 .SH SEE ALSO
1131 .BR ldap (3),
1132 .BR slapd-bdb (5),
1133 .BR slapd-dnssrv (5),
1134 .BR slapd-ldap (5),
1135 .BR slapd-ldbm (5),
1136 .BR slapd-meta (5),
1137 .BR slapd-null (5),
1138 .BR slapd-passwd (5),
1139 .BR slapd-perl (5),
1140 .BR slapd-shell (5),
1141 .BR slapd-sql (5),
1142 .BR slapd-tcl (5),
1143 .BR slapd.replog (5),
1144 .BR slapd.access (5),
1145 .BR locale (5),
1146 .BR slapd (8),
1147 .BR slapadd (8),
1148 .BR slapcat (8),
1149 .BR slapindex (8),
1150 .BR slappasswd (8),
1151 .BR slurpd (8),
1152 .LP
1153 "OpenLDAP Administrator's Guide" (http://www.OpenLDAP.org/doc/admin/)
1154 .SH ACKNOWLEDGEMENTS
1155 .B      OpenLDAP
1156 is developed and maintained by The OpenLDAP Project (http://www.openldap.org/).
1157 .B      OpenLDAP
1158 is derived from University of Michigan LDAP 3.3 Release.