X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=include%2Fclass_password-methods-sha.inc;h=5a6d266ab6f3fea471adb7bf6fe3f6b4a864e825;hb=b55c9da0cc1fed54d967f22d17380948e94d40a0;hp=0780a76e08aa9de288ccb6f91207a9d7ad697894;hpb=c2c6a6e54355a1b67c25bb4d761d847513810d02;p=gosa.git diff --git a/include/class_password-methods-sha.inc b/include/class_password-methods-sha.inc index 0780a76e0..5a6d266ab 100644 --- a/include/class_password-methods-sha.inc +++ b/include/class_password-methods-sha.inc @@ -30,8 +30,6 @@ class passwordMethodsha extends passwordMethod return(true); }elseif(function_exists('mhash')){ return true; - }elseif(function_exists('crypt')){ - return true; }else{ return false; } @@ -44,15 +42,20 @@ class passwordMethodsha extends passwordMethod $hash = "{SHA}" . base64_encode(pack("H*",sha1($password))); }elseif (function_exists('mhash')) { $hash = "{SHA}" . base64_encode(mHash(MHASH_SHA1, $password)); - }elseif(function_exists('crypt')) { - $hash = "{CRYPT}" . crypt($password); }else{ - print_red(_("Can't use sha for encryption, missing function sha1 / mhash / crypt")); + print_red(_("Can't use sha for encryption, missing function sha1 / mhash")); return false; } return $hash; } + + + function get_hash_name() + { + return "sha"; + } + } // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler: