From: Kurt Zeilenga Date: Wed, 2 May 2001 19:46:30 +0000 (+0000) Subject: Use SMD5 is SHA1 is not available X-Git-Tag: LDBM_PRE_GIANT_RWLOCK~1460 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=87dc3e20918a8a15bd1cc74a00412f1f53677827;p=openldap Use SMD5 is SHA1 is not available --- diff --git a/servers/slapd/passwd.c b/servers/slapd/passwd.c index 422f432df3..6e0b31b0e3 100644 --- a/servers/slapd/passwd.c +++ b/servers/slapd/passwd.c @@ -322,7 +322,12 @@ struct berval * slap_passwd_generate( void ) struct berval * slap_passwd_hash( struct berval * cred ) { - char* hash = default_passwd_hash ? default_passwd_hash : "{SSHA}"; +#ifdef LUTIL_SHA1_BYTES + char* hash = default_passwd_hash ? default_passwd_hash : "{SSHA}"; +#else + char* hash = default_passwd_hash ? default_passwd_hash : "{SMD5}"; +#endif + struct berval *new;