summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: be3634b)
raw | patch | inline | side by side (parent: be3634b)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 15 Oct 2007 13:39:05 +0000 (13:39 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 15 Oct 2007 13:39:05 +0000 (13:39 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@7556 594d385d-05f5-0310-b6e9-bd551577e9d8
include/class_password-methods.inc | patch | blob | history | |
include/functions.inc | patch | blob | history |
index 9ed414980e424be0a402f5f8a71a917c21f19858..a23e55e07988a02b94aaa4bb0bec0d8a98dd4240 100644 (file)
}
+ // Method to let password backends remove additional information besides
+ // the userPassword attribute
function remove_from_parent()
{
}
+
+ // Method to let passwords backends manage additional information
+ // besides the userAttribute entry
+ function set_password()
+ {
+ }
+
+
}
// vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
?>
diff --git a/include/functions.inc b/include/functions.inc
index 23300bd08378077963f97edb61757755ad615f2d..2d5dd7b6dcd0989279549a620a3c5d512625900c 100644 (file)
--- a/include/functions.inc
+++ b/include/functions.inc
}
$test = new $available[$hash]($config);
- $test->attrs= $attrs;
$newpass = $test->generate_hash($password);
} else {
- // Crypt it by default
+ // User MD5 by default
+ $hash= "md5";
$test = new $available['md5']($config);
$newpass = $test->generate_hash($password);
}
+ /* Feed password backends with information */
+ $test->dn= $dn;
+ $test->attrs= $attrs;
+
// Update shadow timestamp?
if (isset($attrs["shadowLastChange"][0])){
$shadow= (int)(date("U") / 86400);
$ldap->get_error()));
} else {
+ /* Run backend method for change/create */
+ $test->set_password($password);
+
/* Find postmodify entries for this class */
$command= $config->search("password", "POSTMODIFY",array('menu'));