memory.
The winbind connection caching code isn't exactly a plesent beast, and there is
more work that needs to be done to nail this properly.
Andrew Bartlett
(This used to be commit
dd40ce54b7f170854d63e08ac737f1b4306bd95b)
time_t last_change_time;
uint32 smb_uid_low;
NET_USER_INFO_3 info3;
time_t last_change_time;
uint32 smb_uid_low;
NET_USER_INFO_3 info3;
+ struct cli_state *cli = NULL;
uchar chal[8];
TALLOC_CTX *mem_ctx;
DATA_BLOB lm_resp;
uchar chal[8];
TALLOC_CTX *mem_ctx;
DATA_BLOB lm_resp;
if (!parse_domain_user(state->request.data.auth.user, name_domain,
name_user)) {
DEBUG(5,("no domain seperator (%s) in username (%s) - failing fauth\n", lp_winbind_separator(), state->request.data.auth.user));
if (!parse_domain_user(state->request.data.auth.user, name_domain,
name_user)) {
DEBUG(5,("no domain seperator (%s) in username (%s) - failing fauth\n", lp_winbind_separator(), state->request.data.auth.user));
+ talloc_destroy(mem_ctx);
if (!*state->request.data.auth.pass) {
return WINBINDD_ERROR;
if (!*state->request.data.auth.pass) {
return WINBINDD_ERROR;
+ talloc_destroy(mem_ctx);
} else {
unsigned char local_lm_response[24];
unsigned char local_nt_response[24];
} else {
unsigned char local_lm_response[24];
unsigned char local_nt_response[24];
lp_workgroup(), trust_passwd, &last_change_time)) {
DEBUG(0, ("winbindd_pam_auth: could not fetch trust account "
"password for domain %s\n", lp_workgroup()));
lp_workgroup(), trust_passwd, &last_change_time)) {
DEBUG(0, ("winbindd_pam_auth: could not fetch trust account "
"password for domain %s\n", lp_workgroup()));
+ talloc_destroy(mem_ctx);
uni_group_cache_store_netlogon(mem_ctx, &info3);
done:
uni_group_cache_store_netlogon(mem_ctx, &info3);
done:
+ if (cli)
+ cli_shutdown(cli);
unsigned char trust_passwd[16];
time_t last_change_time;
NET_USER_INFO_3 info3;
unsigned char trust_passwd[16];
time_t last_change_time;
NET_USER_INFO_3 info3;
+ struct cli_state *cli = NULL;
TALLOC_CTX *mem_ctx;
DATA_BLOB lm_resp, nt_resp;
TALLOC_CTX *mem_ctx;
DATA_BLOB lm_resp, nt_resp;
lp_workgroup(), trust_passwd, &last_change_time)) {
DEBUG(0, ("winbindd_pam_auth: could not fetch trust account "
"password for domain %s\n", lp_workgroup()));
lp_workgroup(), trust_passwd, &last_change_time)) {
DEBUG(0, ("winbindd_pam_auth: could not fetch trust account "
"password for domain %s\n", lp_workgroup()));
+ talloc_destroy(mem_ctx);
done:
talloc_destroy(mem_ctx);
done:
talloc_destroy(mem_ctx);
+ if (cli)
+ cli_shutdown(cli);
return NT_STATUS_IS_OK(result) ? WINBINDD_OK : WINBINDD_ERROR;
}
return NT_STATUS_IS_OK(result) ? WINBINDD_OK : WINBINDD_ERROR;
}