]> git.sur5r.net Git - openldap/commitdiff
Use SMD5 is SHA1 is not available
authorKurt Zeilenga <kurt@openldap.org>
Wed, 2 May 2001 19:46:30 +0000 (19:46 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Wed, 2 May 2001 19:46:30 +0000 (19:46 +0000)
servers/slapd/passwd.c

index 422f432df3dfba3bc72ef18578894e63c73d7588..6e0b31b0e338bc53db8e096e3662010137f67a19 100644 (file)
@@ -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;