1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-24 21:34:56 +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 commit is contained in:
Andrew Tridgell 0001-01-01 00:00:00 +00:00
parent 2181d929d1
commit 45f4ae4327

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) {