mirror of
https://github.com/samba-team/samba.git
synced 2025-01-26 10:04:02 +03:00
copy of password struct needed to be made prior to calling copy_passwd_struct
found by Bertl <bs@vpnet.at>.
This commit is contained in:
parent
1a0e378a6f
commit
93298bca1c
@ -472,6 +472,7 @@ BOOL pass_check_smb(char *user, char *domain, uchar *chal,
|
||||
struct passwd *pwd, uchar user_sess_key[16])
|
||||
{
|
||||
const struct passwd *pass;
|
||||
struct passwd pw;
|
||||
struct smb_passwd *smb_pass;
|
||||
|
||||
if (!lm_pwd || !nt_pwd)
|
||||
@ -487,12 +488,13 @@ BOOL pass_check_smb(char *user, char *domain, uchar *chal,
|
||||
else
|
||||
{
|
||||
pass = Get_Pwnam(user,True);
|
||||
}
|
||||
|
||||
if (pass == NULL)
|
||||
{
|
||||
DEBUG(3,("Couldn't find user %s\n",user));
|
||||
return False;
|
||||
if (pass == NULL)
|
||||
{
|
||||
DEBUG(3,("Couldn't find user %s\n",user));
|
||||
return False;
|
||||
}
|
||||
memcpy(&pw, pass, sizeof(struct passwd));
|
||||
pass = &pw;
|
||||
}
|
||||
|
||||
smb_pass = getsmbpwnam(user);
|
||||
|
Loading…
x
Reference in New Issue
Block a user