]> git.sur5r.net Git - openldap/blob - servers/slapd/schema/ppolicy.schema
Password policy schema from draft 7
[openldap] / servers / slapd / schema / ppolicy.schema
1 # $OpenLDAP$
2 ## This work is part of OpenLDAP Software <http://www.openldap.org/>.
3 ##
4 ## Copyright 2004 The OpenLDAP Foundation.
5 ## All rights reserved.
6 ##
7 ## Redistribution and use in source and binary forms, with or without
8 ## modification, are permitted only as authorized by the OpenLDAP
9 ## Public License.
10 ##
11 ## A copy of this license is available in the file LICENSE in the
12 ## top-level directory of the distribution or, alternatively, at
13 ## <http://www.OpenLDAP.org/license.html>.
14 #
15 ## Portions Copyright (C) The Internet Society (2004).  All Rights Reserved.
16 ## Please see full copyright statement below.
17
18 # Definitions from Draft behera-ldap-password-policy-07
19 #       Password Policy for LDAP Directories
20
21 # With extensions from Hewlett-Packard:
22 #       pwdCheckModule etc.
23
24
25 # Internet-Draft                                                P. Behera
26 # draft behera-ldap-password-policy-07.txt                      L. Poitou
27 # Intended Category: Proposed Standard                   Sun Microsystems
28 # Expires: August 2004                                     J. Sermersheim
29 #                                                                  Novell
30
31 #                                                           February 2004
32 #  
33 #  
34 #                   Password Policy for LDAP Directories 
35 #  
36 #  
37 # Status of this Memo 
38 #  
39 #    This document is an Internet-Draft and is in full conformance with 
40 #    all provisions of Section 10 of RFC 2026.  
41 #     
42 #    Internet-Drafts are working documents of the Internet Engineering 
43 #    Task Force (IETF), its areas, and its working groups. Note that 
44 #    other groups may also distribute working documents as Internet-
45 #    Drafts. 
46 #     
47 #    Internet-Drafts are draft documents valid for a maximum of six 
48 #    months and may be updated, replaced, or obsoleted by other documents 
49 #    at any time. It is inappropriate to use Internet- Drafts as 
50 #    reference material or to cite them other than as "work in progress." 
51 #      
52 #    The list of current Internet-Drafts can be accessed at 
53 #    http://www.ietf.org/ietf/1id-abstracts.txt  
54 #     
55 #    The list of Internet-Draft Shadow Directories can be accessed at 
56 #    http://www.ietf.org/shadow.html. 
57 #     
58 #    Technical discussions of this draft are held on the LDAPEXT Working 
59 #    Group mailing list at ietf-ldapext@netscape.com. Editorial comments 
60 #    may be sent to the authors listed in Section 13. 
61 #     
62 #    Copyright (C) The Internet Society (2004). All rights Reserved. 
63 #     
64 #    Please see the Copyright Section near the end of this document for 
65 #    more information. 
66 #     
67 #     
68 # 1. Abstract 
69 #     
70 #    Password policy as described in this document is a set of rules that 
71 #    controls how passwords are used and administered in LDAP 
72 #    directories. In order to improve the security of LDAP directories 
73 #    and make it difficult for password cracking programs to break into 
74 #    directories, it is desirable to enforce a set of rules on password 
75 #    usage.  These rules are made to ensure that users change their 
76 #    passwords periodically, passwords meet construction requirements, 
77 #    the re-use of old password is restricted, and users are locked out 
78 #    after a certain number of failed attempts. 
79 #     
80 # [trimmed]
81
82 #     
83 # 4.2. Attribute Types used in the pwdPolicy ObjectClass 
84 #     
85 #    Following are the attribute types used by the pwdPolicy object 
86 #    class. 
87 #     
88 # 4.2.1. pwdAttribute 
89 #     
90 #    This holds the name of the attribute to which the password policy is 
91 #    applied. For example, the password policy may be applied to the 
92 #    userPassword attribute. 
93     
94 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.1 
95       NAME 'pwdAttribute' 
96       EQUALITY objectIdentifierMatch 
97       SYNTAX 1.3.6.1.4.1.1466.115.121.1.38 ) 
98     
99 # 4.2.2. pwdMinAge  
100 #     
101 #    This attribute holds the number of seconds that must elapse between 
102 #    modifications to the password. If this attribute is not present, 0 
103 #    seconds is assumed. 
104     
105 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.2 
106       NAME 'pwdMinAge' 
107       EQUALITY integerMatch 
108       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27  
109       SINGLE-VALUE ) 
110     
111 # 4.2.3. pwdMaxAge 
112 #     
113 #    This attribute holds the number of seconds after which a modified 
114 #    password will expire. 
115 #     
116 #    If this attribute is not present, or if the value is 0 the password 
117 #    does not expire. If not 0, the value must be greater than or equal 
118 #    to the value of the pwdMinAge. 
119     
120 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.3 
121       NAME 'pwdMaxAge' 
122       EQUALITY integerMatch 
123       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 
124       SINGLE-VALUE ) 
125     
126 # 4.2.4. pwdInHistory 
127 #     
128 #    This attribute specifies the maximum number of used passwords stored 
129 #    in the pwdHistory attribute. 
130 #     
131 #    If this attribute is not present, or if the value is 0, used 
132 #    passwords are not stored in the pwdHistory attribute and thus may be 
133 #    reused. 
134     
135 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.4 
136       NAME 'pwdInHistory' 
137       EQUALITY integerMatch 
138       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 
139       SINGLE-VALUE ) 
140     
141 # 4.2.5. pwdCheckQuality 
142 #     
143 #    This attribute indicates how the password quality will be verified 
144 #    while being modified or added. If this attribute is not present, or 
145 #    if the value is '0', quality checking will not be enforced. A value 
146 #    of '1' indicates that the server will check the quality, and if the 
147 #    server is unable to check it (due to a hashed password or other 
148 #    reasons) it will be accepted. A value of '2' indicates that the 
149 #    server will check the quality, and if the server is unable to verify 
150 #    it, it will return an error refusing the password. 
151     
152 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.5 
153       NAME 'pwdCheckQuality' 
154       EQUALITY integerMatch 
155       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27  
156       SINGLE-VALUE ) 
157     
158 # 4.2.6. pwdMinLength 
159 #     
160 #    When quality checking is enabled, this attribute holds the minimum 
161 #    number of characters that must be used in a password. If this 
162 #    attribute is not present, no minimum password length will be 
163 #    enforced. If the server is unable to check the length (due to a 
164 #    hashed password or otherwise), the server will, depending on the 
165 #    value of the pwdCheckQuality attribute, either accept the password 
166 #    without checking it ('0' or '1') or refuse it ('2'). 
167     
168 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.6 
169       NAME 'pwdMinLength' 
170       EQUALITY integerMatch 
171       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 
172       SINGLE-VALUE ) 
173     
174 # 4.2.7. pwdExpireWarning 
175 #     
176 #    This attribute specifies the maximum number of seconds before a 
177 #    password is due to expire that expiration warning messages will be 
178 #    returned to an authenticating user. If this attribute is not 
179 #    present, or if the value is 0 no warnings will be sent. If not 0, 
180 #    the value must be smaller than the value of the pwdMaxAge attribute. 
181     
182 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.7 
183       NAME 'pwdExpireWarning' 
184       EQUALITY integerMatch 
185       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27  
186       SINGLE-VALUE ) 
187     
188 # 4.2.8. pwdGraceLoginLimit 
189 #     
190 #    This attribute specifies the number of times an expired password can 
191 #    be used to authenticate. If this attribute is not present or if the 
192 #    value is 0, authentication will fail. 
193     
194 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.8 
195       NAME 'pwdGraceLoginLimit' 
196       EQUALITY integerMatch 
197       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27  
198       SINGLE-VALUE ) 
199     
200 # 4.2.9. pwdLockout 
201 #     
202 #    This attribute indicates, when its value is "TRUE", that the 
203 #    password may not be used to authenticate after a specified number of 
204 #    consecutive failed bind attempts. The maximum number of consecutive 
205 #    failed bind attempts is specified in pwdMaxFailure. 
206 #     
207 #    If this attribute is not present, or if the value is "FALSE", the 
208 #    password may be used to authenticate when the number of failed bind 
209 #    attempts has been reached. 
210     
211 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.9 
212       NAME 'pwdLockout' 
213       EQUALITY booleanMatch 
214       SYNTAX 1.3.6.1.4.1.1466.115.121.1.7  
215       SINGLE-VALUE ) 
216
217 # 4.2.10. pwdLockoutDuration 
218 #     
219 #    This attribute holds the number of seconds that the password cannot 
220 #    be used to authenticate due to too many failed bind attempts. If 
221 #    this attribute is not present, or if the value is 0 the password 
222 #    cannot be used to authenticate until reset by an administrator. 
223     
224 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.10 
225       NAME 'pwdLockoutDuration' 
226       EQUALITY integerMatch 
227       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27  
228       SINGLE-VALUE ) 
229     
230 # 4.2.11. pwdMaxFailure 
231 #     
232 #    This attribute specifies the number of consecutive failed bind 
233 #    attempts after which the password may not be used to authenticate. 
234 #    If this attribute is not present, or if the value is 0, this policy 
235 #    is not checked, and the value of pwdLockout will be ignored. 
236     
237 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.11 
238       NAME 'pwdMaxFailure' 
239       EQUALITY integerMatch 
240       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27  
241       SINGLE-VALUE ) 
242     
243 # 4.2.12. pwdFailureCountInterval 
244 #     
245 #    This attribute holds the number of seconds after which the password 
246 #    failures are purged from the failure counter, even though no 
247 #    successful authentication occurred. 
248 #     
249 #    If this attribute is not present, or if its value is 0, the failure 
250 #    counter is only reset by a successful authentication. 
251      
252 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.12 
253       NAME 'pwdFailureCountInterval' 
254       EQUALITY integerMatch 
255       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27  
256       SINGLE-VALUE ) 
257     
258 # 4.2.13. pwdMustChange 
259 #     
260 #    This attribute specifies with a value of "TRUE" that users must 
261 #    change their passwords when they first bind to the directory after a 
262 #    password is set or reset by the administrator. If this attribute is 
263 #    not present, or if the value is "FALSE", users are not required to 
264 #    change their password upon binding after the administrator sets or 
265 #    resets the password. 
266  
267 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.13 
268       NAME 'pwdMustChange' 
269       EQUALITY booleanMatch 
270       SYNTAX 1.3.6.1.4.1.1466.115.121.1.7  
271       SINGLE-VALUE ) 
272     
273 # 4.2.14. pwdAllowUserChange 
274 #     
275 #    This attribute indicates whether users can change their own 
276 #    passwords, although the change operation is still subject to access 
277 #    control. If this attribute is not present, a value of "TRUE" is 
278 #    assumed. 
279     
280 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.14 
281       NAME 'pwdAllowUserChange' 
282       EQUALITY booleanMatch 
283       SYNTAX 1.3.6.1.4.1.1466.115.121.1.7  
284       SINGLE-VALUE ) 
285     
286 # 4.2.15. pwdSafeModify 
287 #     
288 #    This attribute specifies whether or not the existing password must 
289 #    be sent when changing a password. If this attribute is not present, 
290 #    a "FALSE" value is assumed. 
291 #     
292 attributetype   (  1.3.6.1.4.1.42.2.27.8.1.15 
293       NAME 'pwdSafeModify' 
294       EQUALITY booleanMatch 
295       SYNTAX 1.3.6.1.4.1.1466.115.121.1.7  
296       SINGLE-VALUE ) 
297
298 # HP extensions
299 #
300 # pwdCheckModule
301 #
302 #    This attribute names a user-defined loadable module that provides
303 #    a check_password() function. If pwdCheckQuality is set to '1' or '2'
304 #    this function will be called after all of the internal password
305 #    quality checks have been passed. The function has this prototype:
306 #
307 #    int check_password( char *password, char **errormessage, void *arg )
308 #
309 #    The function should return LDAP_SUCCESS for a valid password.
310
311 attributetype  (  1.3.6.1.4.1.42.2.27.8.1.99
312      NAME 'pwdCheckModule'
313      EQUALITY caseExactIA5Match
314      SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
315      DESC 'Loadable module that instantiates "check_password() function'
316      SINGLE-VALUE )
317
318 # 4.1. The pwdPolicy Object Class 
319 #     
320 #    This object class contains the attributes defining a password policy 
321 #    in effect for a set of users. Section 8 describes the administration 
322 #    of this object, and the relationship between it and particular 
323 #    objects. 
324     
325 objectclass   (  1.3.6.1.4.1.42.2.27.8.2.1 
326       NAME 'pwdPolicy'  
327       SUP top 
328       AUXILIARY  
329       MUST ( pwdAttribute ) 
330       MAY ( pwdMinAge $ pwdMaxAge $ pwdInHistory $ pwdCheckQuality $ 
331       pwdMinLength $ pwdExpireWarning $ pwdGraceLoginLimit $ pwdLockout 
332       $ pwdLockoutDuration $ pwdMaxFailure $ pwdFailureCountInterval $ 
333       pwdMustChange $ pwdAllowUserChange $ pwdSafeModify $ pwdCheckModule ) ) 
334
335 # 4.3. Attribute Types for Password Policy State Information 
336 #     
337 #    Password policy state information must be maintained for each user. 
338 #    The information is located in each user entry as a set of 
339 #    operational attributes. These operational attributes are: 
340 #    pwdChangedTime, pwdAccountLockedTime, pwdExpirationWarned, 
341 #    pwdFailureTime, pwdHistory, pwdGraceUseTime, pwdReset, 
342 #    pwdPolicySubEntry. 
343 #     
344 # 4.3.1. Password Policy State Attribute Option 
345 #     
346 #    Since the password policy could apply to several attributes used to 
347 #    store passwords, each of the above operational attributes must have 
348 #    an option to specify which pwdAttribute is applies to.  
349 #    The password policy option is defined as the following: 
350 #         pwd-<passwordAttribute> 
351 #     
352 #    where passwordAttribute a string following the OID syntax 
353 #    (1.3.6.1.4.1.1466.115.121.1.38). The attribute type descriptor 
354 #    (short name) MUST be used. 
355 #     
356 #    For example, if the pwdPolicy object has for pwdAttribute 
357 #    "userPassword" then the pwdChangedTime operational attribute, in a 
358 #    user entry, will be: 
359 #    pwdChangedTime;pwd-userPassword: 20000103121520Z 
360 #     
361 #    This attribute option follows sub-typing semantics. If a client 
362 #    requests a password policy state attribute to be returned in a 
363 #    search operation, and does not specify an option, all subtypes of 
364 #    that policy state attribute are returned. 
365 #          
366 # 4.3.2. pwdChangedTime 
367 #     
368 #    This attribute specifies the last time the entry's password was 
369 #    changed. This is used by the password expiration policy. If this 
370 #    attribute does not exist, the password will never expire. 
371 #     
372 #    (  1.3.6.1.4.1.42.2.27.8.1.16 
373 #       NAME 'pwdChangedTime' 
374 #       DESC 'The time the password was last changed' 
375 #       SYNTAX 1.3.6.1.4.1.1466.115.121.1.24 
376 #       EQUALITY generalizedTimeMatch 
377 #       ORDERING generalizedTimeOrderingMatch 
378 #       SINGLE-VALUE 
379 #       USAGE directoryOperation) 
380 #     
381 # 4.3.3. pwdAccountLockedTime 
382 #     
383 #    This attribute holds the time that the user's account was locked. A 
384 #    locked account means that the password may no longer be used to 
385 #    authenticate. A 0 value means that the account has been locked 
386 #    permanently, and that only an administrator can unlock the account. 
387 #     
388 #    (  1.3.6.1.4.1.42.2.27.8.1.17 
389 #       NAME 'pwdAccountLockedTime' 
390 #       DESC 'The time an user account was locked' 
391 #       SYNTAX 1.3.6.1.4.1.1466.115.121.1.24 
392 #       EQUALITY generalizedTimeMatch 
393 #       ORDERING generalizedTimeOrderingMatch 
394 #       SINGLE-VALUE 
395 #       USAGE directoryOperation) 
396 #      
397 # 4.3.4. pwdExpirationWarned 
398 #  
399 #    This attribute contains the time when the password expiration 
400 #    warning was first sent to the client. The password will expire in 
401 #    the pwdExpireWarning time. 
402 #     
403 #    (  1.3.6.1.4.1.42.2.27.8.1.18 
404 #       NAME 'pwdExpirationWarned' 
405 #       DESC 'The time the user was first warned about the coming 
406 #               expiration of the password' 
407 #       SYNTAX 1.3.6.1.4.1.1466.115.121.1.24 
408 #       EQUALITY generalizedTimeMatch 
409 #       ORDERING generalizedTimeOrderingMatch 
410 #       SINGLE-VALUE 
411 #       USAGE directoryOperation ) 
412 #     
413 # 4.3.5. pwdFailureTime 
414 #     
415 #    This attribute holds the timestamps of the consecutive 
416 #    authentication failures. 
417 #     
418 #    (  1.3.6.1.4.1.42.2.27.8.1.19 
419 #       NAME 'pwdFailureTime' 
420 #       DESC 'The timestamps of the last consecutive authentication 
421 #               failures' 
422 #       SYNTAX 1.3.6.1.4.1.1466.115.121.1.24 
423 #       EQUALITY generalizedTimeMatch 
424 #       ORDERING generalizedTimeOrderingMatch 
425 #       USAGE directoryOperation ) 
426 #     
427 # 4.3.6. pwdHistory 
428 #     
429 #    This attribute holds a history of previously used passwords. 
430 #     
431 #    Values of this attribute are transmitted in string format as given 
432 #    by the following ABNF: 
433 #     
434 #    pwdHistory = time "#" syntaxOID "#" length "#" data 
435 #     
436 #    time         = <generalizedTimeString as specified in 6.14 of 
437 #                   [RFC2252]> 
438 #     
439 #    syntaxOID    = numericoid     ; the string representation of the  
440 #                                  ; dotted-decimal OID that defines the 
441 #                                  ; syntax used to store the password. 
442 #                                  ; numericoid is described in 4.1 of 
443 #                                  ; [RFC2252]. 
444 #       
445 #    length       = numericstring  ; the number of octets in data. 
446 #                                  ; numericstring is described in 4.1 of 
447 #                                  ; [RFC2252]. 
448 #     
449 #    data         = <octets representing the password in the format      
450 #                 specified by syntaxOID>. 
451 #     
452 #    This format allows the server to store, and transmit a history of 
453 #    passwords that have been used. In order for equality matching to 
454 #    function properly, the time field needs to adhere to a consistent 
455 #    format. For this purpose, the time field MUST be in GMT format. 
456 #     
457 #    (  1.3.6.1.4.1.42.2.27.8.1.20 
458 #       NAME 'pwdHistory' 
459 #       DESC 'The history of user s passwords' 
460 #       SYNTAX 1.3.6.1.4.1.1466.115.121.1.40 
461 #       EQUALITY octetStringMatch 
462 #       USAGE directoryOperation) 
463 #     
464 # 4.3.7. pwdGraceUseTime 
465 #     
466 #    This attribute holds the timestamps of grace login once a password 
467 #    has expired. 
468 #     
469 #    (  1.3.6.1.4.1.42.2.27.8.1.21 
470 #       NAME 'pwdGraceUseTime' 
471 #       DESC 'The timestamps of the grace login once the password has 
472 #       expired' 
473 #       SYNTAX 1.3.6.1.4.1.1466.115.121.1.24 
474 #       EQUALITY generalizedTimeMatch 
475 #        
476 #       USAGE directoryOperation) 
477 #     
478 # 4.3.8. pwdReset 
479 #     
480 #    This attribute holds a flag to indicate (when TRUE) that the 
481 #    password has been reset and therefore must be changed by the user on 
482 #    first authentication. 
483 #     
484 #    (  1.3.6.1.4.1.42.2.27.8.1.22 
485 #       NAME 'pwdReset' 
486 #       DESC 'The indication that the password has been reset' 
487 #       EQUALITY booleanMatch 
488 #       SYNTAX 1.3.6.1.4.1.1466.115.121.1.7 
489 #       SINGLE-VALUE 
490 #       USAGE directoryOperation) 
491 #     
492 # 4.3.9. pwdPolicySubentry 
493 #     
494 #    This attribute points to the pwdPolicy subentry in effect for this 
495 #    object. 
496 #     
497 #    (  1.3.6.1.4.1.42.2.27.8.1.23 
498 #       NAME 'pwdPolicySubentry' 
499 #       DESC 'The pwdPolicy subentry in effect for this object' 
500 #       EQUALITY distinguishedNameMatch 
501 #       SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 
502 #       SINGLE-VALUE 
503 #       USAGE directoryOperation) 
504 #     
505 # 14. Copyright Notice 
506 #     
507 #    Copyright (C) The Internet Society (2004). All Rights  
508 #    Reserved.   
509 #      
510 #    This document and translations of it may be copied and furnished to 
511 #    others, and derivative works that comment on or otherwise explain it 
512 #    or assist in its implementation may be prepared, copied, published 
513 #    and distributed, in whole or in part, without restriction of any 
514 #    kind, provided that the above copyright notice and this paragraph 
515 #    are included on all such copies and derivative works. However, this 
516 #    document itself may not be modified in any way, such as by removing 
517 #    the copyright notice or references to the Internet Society or other 
518 #    Internet organizations, except as needed for the purpose of 
519 #    developing Internet standards in which case the procedures for 
520 #    copyrights defined in the Internet Standards process must be 
521 #    followed, or as required to translate it into languages other than 
522 #    English.  
523 #      
524 #    The limited permissions granted above are perpetual and will not be 
525 #    revoked by the Internet Society or its successors or assigns.  
526 #      
527 #    This document and the information contained herein is provided on an 
528 #    "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING 
529 #    TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING 
530 #    BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION 
531 #    HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF  
532 #    MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE."