Lines 605-611
def password_sync_ucs_to_s4(s4connector, key, object):
|
Link Here
|
---|
|
605 |
if pwdHistoryLength: |
605 |
if pwdHistoryLength: |
606 |
userobject = s4connector.get_ucs_object(key, ucs_object['dn']) |
606 |
userobject = s4connector.get_ucs_object(key, ucs_object['dn']) |
607 |
pwhistoryPolicy = userobject.loadPolicyObject('policies/pwhistory') |
607 |
pwhistoryPolicy = userobject.loadPolicyObject('policies/pwhistory') |
608 |
pwhistory_length = int(pwhistoryPolicy['length']) |
608 |
pwhistory_length = int(pwhistoryPolicy.get('length', 0)) |
609 |
if pwhistory_length != pwdHistoryLength: |
609 |
if pwhistory_length != pwdHistoryLength: |
610 |
ud.debug(ud.LDAP, ud.WARN, "password_sync_ucs_to_s4: Mismatch between UCS pwhistoryPolicy (%s) and S4 pwhistoryPolicy (%s). Using the larger one." % (pwhistory_length, pwdHistoryLength)) |
610 |
ud.debug(ud.LDAP, ud.WARN, "password_sync_ucs_to_s4: Mismatch between UCS pwhistoryPolicy (%s) and S4 pwhistoryPolicy (%s). Using the larger one." % (pwhistory_length, pwdHistoryLength)) |
611 |
des_len = max(pwdHistoryLength, pwhistory_length) * 16 |
611 |
des_len = max(pwdHistoryLength, pwhistory_length) * 16 |