[SCM] Samba Shared Repository - branch v3-devel updated - release-3-2-0pre2-3807-g25293ba

Gerald Carter jerry at samba.org
Fri Aug 22 19:59:22 GMT 2008


The branch, v3-devel has been updated
       via  25293ba1507f8f8fa7e33c302200184e980bb123 (commit)
       via  5ce4a2ae6697970ea37d0078a506615b4b7a9a9c (commit)
      from  b868463015dedc684eb13d12118a98ccca71250a (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-devel


- Log -----------------------------------------------------------------
commit 25293ba1507f8f8fa7e33c302200184e980bb123
Author: Gerald (Jerry) Carter <jerry at samba.org>
Date:   Fri Aug 22 14:54:50 2008 -0500

    idmap_gid_to_sid: Fix a cut-a-npaste error.
    
    The call was looking up a uid and not gid in the cache.

commit 5ce4a2ae6697970ea37d0078a506615b4b7a9a9c
Author: Gerald (Jerry) Carter <jerry at samba.org>
Date:   Fri Aug 22 10:17:04 2008 -0500

    winbindd: Fix crash in cm_connect_sam()
    
    Fix segv when talking to parent DC (joined to child domain).
    
    The root cause was
    
    (a) storing the parent domain in the cli_state struct caused
        the NTLMSSP pipe bind to fail which made us fallover to
        the schannel code path
    (b) the dcinfo pointer in cm_get_schannel_dcinfo() was returning
        NULL even though the function indicated success.

-----------------------------------------------------------------------

Summary of changes:
 source/winbindd/idmap_util.c  |    2 +-
 source/winbindd/winbindd_cm.c |    9 +++++++--
 2 files changed, 8 insertions(+), 3 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source/winbindd/idmap_util.c b/source/winbindd/idmap_util.c
index 2a6beca..b10a1a4 100644
--- a/source/winbindd/idmap_util.c
+++ b/source/winbindd/idmap_util.c
@@ -87,7 +87,7 @@ NTSTATUS idmap_gid_to_sid(const char *domname, DOM_SID *sid, gid_t gid)
 
 	DEBUG(10,("gid = [%lu]\n", (unsigned long)gid));
 
-	if (idmap_cache_find_uid2sid(gid, sid, &expired)) {
+	if (idmap_cache_find_gid2sid(gid, sid, &expired)) {
 		DEBUG(10, ("idmap_cache_find_gid2sid found %d%s\n", gid,
 			   expired ? " (expired)": ""));
 		if (expired && idmap_is_online()) {
diff --git a/source/winbindd/winbindd_cm.c b/source/winbindd/winbindd_cm.c
index 69e95b1..6db45f7 100644
--- a/source/winbindd/winbindd_cm.c
+++ b/source/winbindd/winbindd_cm.c
@@ -875,7 +875,7 @@ static NTSTATUS cm_prepare_connection(const struct winbindd_domain *domain,
 			result = ads_ntstatus(ads_status);
 			if (NT_STATUS_IS_OK(result)) {
 				/* Ensure creds are stored for NTLMSSP authenticated pipe access. */
-				cli_init_creds(*cli, machine_account, domain->name, machine_password);
+				cli_init_creds(*cli, machine_account, lp_workgroup(), machine_password);
 				goto session_setup_done;
 			}
 		}
@@ -900,7 +900,7 @@ static NTSTATUS cm_prepare_connection(const struct winbindd_domain *domain,
 		result = ads_ntstatus(ads_status);
 		if (NT_STATUS_IS_OK(result)) {
 			/* Ensure creds are stored for NTLMSSP authenticated pipe access. */
-			cli_init_creds(*cli, machine_account, domain->name, machine_password);
+			cli_init_creds(*cli, machine_account, lp_workgroup(), machine_password);
 			goto session_setup_done;
 		}
 	}
@@ -1927,6 +1927,10 @@ static bool cm_get_schannel_dcinfo(struct winbindd_domain *domain,
 	/* Return a pointer to the struct dcinfo from the
 	   netlogon pipe. */
 
+	if (!domain->conn.netlogon_pipe->dc) {
+		return false;
+	}
+
 	*ppdc = domain->conn.netlogon_pipe->dc;
 	return True;
 }
@@ -1953,6 +1957,7 @@ NTSTATUS cm_connect_sam(struct winbindd_domain *domain, TALLOC_CTX *mem_ctx,
 		goto done;
 	}
 
+
 	/*
 	 * No SAMR pipe yet. Attempt to get an NTLMSSP SPNEGO authenticated
 	 * sign and sealed pipe using the machine account password by


-- 
Samba Shared Repository


More information about the samba-cvs mailing list