Commit 6954036c authored by Côme Bernigaud's avatar Côme Bernigaud Committed by Benoit Mortier
Browse files

Fixes #3458 not adding samba attributes when samba plugin is not there

parent c3665962
......@@ -3051,6 +3051,7 @@ function change_password ($dn, $password, $mode = 0, $hash = "")
// Not for groups
if ($mode == 0) {
if (class_available('sambaAccount')) {
if ($test->need_password()) {
// Create SMB Password
$attrs = generate_smb_nt_hash($password);
......@@ -3061,6 +3062,7 @@ function change_password ($dn, $password, $mode = 0, $hash = "")
$attrs['sambaBadPasswordCount'] = array();
$attrs['sambaBadPasswordTime'] = array();
}
}
if ($shadow != 0) {
$attrs['shadowLastChange'] = $shadow;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment