mirror of
https://github.com/samba-team/samba.git
synced 2025-12-09 00:23:50 +03:00
r3525: Fix a memleak
Volker
This commit is contained in:
committed by
Gerald (Jerry) Carter
parent
43a7f7db3d
commit
4c4da26aa1
@@ -93,6 +93,7 @@ static BOOL smb_pwd_check_ntlmv2(const DATA_BLOB *ntv2_response,
|
|||||||
uchar value_from_encryption[16];
|
uchar value_from_encryption[16];
|
||||||
uchar client_response[16];
|
uchar client_response[16];
|
||||||
DATA_BLOB client_key_data;
|
DATA_BLOB client_key_data;
|
||||||
|
BOOL res;
|
||||||
|
|
||||||
if (part_passwd == NULL) {
|
if (part_passwd == NULL) {
|
||||||
DEBUG(10,("No password set - DISALLOWING access\n"));
|
DEBUG(10,("No password set - DISALLOWING access\n"));
|
||||||
@@ -146,7 +147,10 @@ static BOOL smb_pwd_check_ntlmv2(const DATA_BLOB *ntv2_response,
|
|||||||
dump_data(100, value_from_encryption, 16);
|
dump_data(100, value_from_encryption, 16);
|
||||||
#endif
|
#endif
|
||||||
data_blob_clear_free(&client_key_data);
|
data_blob_clear_free(&client_key_data);
|
||||||
return (memcmp(value_from_encryption, client_response, 16) == 0);
|
res = (memcmp(value_from_encryption, client_response, 16) == 0);
|
||||||
|
if ((!res) && (user_sess_key != NULL))
|
||||||
|
data_blob_clear_free(user_sess_key);
|
||||||
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user