summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2010-09-08 18:09:07 -0700
committerVolker Lendecke <vl@samba.org>2010-09-09 06:19:24 +0200
commit6f1916524bb1f7d38130ba273e3bebe0c93f3a74 (patch)
treeb7453d80f1772ff656185c2ab8ab92fcaccfcf2d
parentf50687153861efcbac2cbd281ab24141ea83167b (diff)
downloadsamba-6f1916524bb1f7d38130ba273e3bebe0c93f3a74.tar.gz
samba-6f1916524bb1f7d38130ba273e3bebe0c93f3a74.tar.bz2
samba-6f1916524bb1f7d38130ba273e3bebe0c93f3a74.zip
s3: Fill in workstation in winbindd_pam_auth_crap_send
-rw-r--r--source3/winbindd/winbindd_pam.c7
-rw-r--r--source3/winbindd/winbindd_pam_auth_crap.c4
2 files changed, 5 insertions, 6 deletions
diff --git a/source3/winbindd/winbindd_pam.c b/source3/winbindd/winbindd_pam.c
index 47bcb6a847..eda812ef3c 100644
--- a/source3/winbindd/winbindd_pam.c
+++ b/source3/winbindd/winbindd_pam.c
@@ -1690,16 +1690,11 @@ enum winbindd_result winbindd_dual_pam_auth_crap(struct winbindd_domain *domain,
name_user = state->request->data.auth_crap.user;
name_domain = state->request->data.auth_crap.domain;
+ workstation = state->request->data.auth_crap.workstation;
DEBUG(3, ("[%5lu]: pam auth crap domain: %s user: %s\n", (unsigned long)state->pid,
name_domain, name_user));
- if (*state->request->data.auth_crap.workstation) {
- workstation = state->request->data.auth_crap.workstation;
- } else {
- workstation = global_myname();
- }
-
if (state->request->data.auth_crap.lm_resp_len > sizeof(state->request->data.auth_crap.lm_resp)
|| state->request->data.auth_crap.nt_resp_len > sizeof(state->request->data.auth_crap.nt_resp)) {
if (!(state->request->flags & WBFLAG_BIG_NTLMV2_BLOB) ||
diff --git a/source3/winbindd/winbindd_pam_auth_crap.c b/source3/winbindd/winbindd_pam_auth_crap.c
index d62c4aa209..d9f0273219 100644
--- a/source3/winbindd/winbindd_pam_auth_crap.c
+++ b/source3/winbindd/winbindd_pam_auth_crap.c
@@ -80,6 +80,10 @@ struct tevent_req *winbindd_pam_auth_crap_send(
fstrcpy(request->data.auth_crap.domain, domain->name);
+ if (request->data.auth_crap.workstation[0] == '\0') {
+ fstrcpy(request->data.auth_crap.workstation, global_myname());
+ }
+
subreq = wb_domain_request_send(state, winbind_event_context(), domain,
request);
if (tevent_req_nomem(subreq, req)) {