cgrzemba / 389-ds-base

Forked from 389-ds-base 5 years ago
Clone

1feebbd Bug 700145 - userpasswd not replicating

Authored and Committed by rmeggins 13 years ago
    Bug 700145 - userpasswd not replicating
    
    https://bugzilla.redhat.com/show_bug.cgi?id=700145
    Resolves: bug 700145
    Bug Description: userpasswd not replicating
    Reviewed by: nkinder, nhosoi (Thanks!)
    Branch: 389-ds-base-1.2.8
    Fix Description: The problem is happening because we are replicating
    the unhashed#user#password attribute.  The consumer gets this sequence:
    
    delete: unhashed#user#password
    -
    add: unhashed#user#password
    unhashed#user#password: value
    
    The code in entry_wsi_apply_mod attempts to apply the delete, but since the
    attribute does not exist, it returns LDAP_NO_SUCH_ATTRIBUTE and the entire
    modify operation is rejected.  The server removes unhashed#user#password before
    doing database operations in the non-replicated case, but in the replicated
    case it is assumed we can just apply the operations as they are given by the
    supplier.  pw_change is never set in the replicated case, so the consumer
    never removes unhashed#user#password.  The solution is to just remove
    unhashed#user#password even if pw_change is not set.  If the attribute is
    not in the mods list, remove_mod is a no-op.
    Platforms tested: RHEL6 x86_64
    Flag Day: no
    Doc impact: no
    (cherry picked from commit 74e81521ccc3913e8672cdd5713f832a2c6a09c3)
    
        
file modified
+7 -4