1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00

force the salt to be a maximum of 2 characters long in calls

to crypt()

This might solve some password problems, particulary on HPUX
(This used to be commit 45f4ae4327)
This commit is contained in:
Andrew Tridgell 1997-10-15 04:04:38 +00:00
parent 4a9e9a40dc
commit 91e56c7b7b

View File

@ -1047,6 +1047,7 @@ BOOL password_ok(char *user,char *password, int pwlen, struct passwd *pwd)
/* extract relevant info */
strcpy(this_user,pass->pw_name);
strcpy(this_salt,pass->pw_passwd);
this_salt[2] = 0;
strcpy(this_crypted,pass->pw_passwd);
if (!*this_crypted) {