diff --git a/setup/inc/hook_config.inc.php b/setup/inc/hook_config.inc.php index 83544f6a39..7086fa1812 100644 --- a/setup/inc/hook_config.inc.php +++ b/setup/inc/hook_config.inc.php @@ -166,13 +166,17 @@ function passwdhashes($config) { $hashes['ext_crypt'] = 'ext_crypt'; } + if(@defined('CRYPT_STD_DES') && CRYPT_STD_DES == 1) + { + $hashes['crypt'] = 'crypt'; + } $hashes += array( 'md5' => 'md5', 'plain' => 'plain', ); - return _options_from($hashes, $config['ldap_encryption_type']); + return _options_from($hashes, $config['ldap_encryption_type'] ? $config['ldap_encryption_type'] : 'crypt'); } function sql_passwdhashes($config) @@ -206,7 +210,7 @@ function sql_passwdhashes($config) 'plain' => 'plain', ); - return _options_from($hashes, $config['sql_encryption_type']); + return _options_from($hashes, $config['sql_encryption_type'] ? $config['sql_encryption_type'] : 'md5'); } /**