]> git.sur5r.net Git - openldap/commitdiff
ITS#4970 from HEAD
authorHoward Chu <hyc@openldap.org>
Fri, 8 Jun 2007 10:15:06 +0000 (10:15 +0000)
committerHoward Chu <hyc@openldap.org>
Fri, 8 Jun 2007 10:15:06 +0000 (10:15 +0000)
servers/slapd/overlays/ppolicy.c

index 7524572fb6cdc08b26a3322d65fe91eb9310287c..94f9f29002b4d9a50e685e993c36fce9019dba89 100644 (file)
@@ -1692,7 +1692,10 @@ ppolicy_modify( Operation *op, SlapReply *rs )
                goto return_results;
        }
 
-       if (pp.pwdMinAge > 0) {
+       /* Check age, but only if pwdReset is not TRUE */
+       pa = attr_find( e->e_attrs, ad_pwdReset );
+       if ((!pa || !bvmatch( &pa->a_nvals[0], &slap_true_bv )) &&
+               pp.pwdMinAge > 0) {
                time_t pwtime = (time_t)-1, now;
                int age;