Fixed ldapsearch uninitialized fp bug
Fixed Pth initialization bug
Fixed libldap/add mod_bvalues typo
+ Fixed ldappasswd crypt(3) crash (ITD#598)
Build Environment
Remove extra Digital UNIX symbol (ITS#590)
Ignore make clean rm failure
crypted_pw = crypt (pw_in, (char *)lsalt.salt);
free (lsalt.salt);
}
- return (STRDUP (crypted_pw));
+
+ if( crypted_pw == NULL || crypted_pw[0] = '\0' )
+ return NULL;
+
+ return STRDUP(crypted_pw);
}
#endif
hashed_pw = hashes[htype].func (newpw, salt->len ? salt : NULL);
/* return salt back to it's original state */
- if (want_salt)
- {
+ if (want_salt) {
free (salt->salt);
salt->salt = NULL;
}
+ if( hashed_pw == NULL || hashed_pw[0] == '\0' ) {
+ free( hashed_pw );
+ return 1;
+ }
+
buf = (char *)malloc (hashes[htype].namesz + 3 + strlen (hashed_pw));
if (htype)
sprintf (buf, "{%s}%s", hashes[htype].name, hashed_pw);