[PATCH] winbindd broken KDC search

Alexander Bokovoy a.bokovoy at sam-solutions.net
Wed Dec 19 03:32:02 GMT 2001


Latest CVS HEAD version of winbindd has broken support for KDC
due integration of trusted domains support. This patch fixes a problem by
introducing fallback for old (correct) method for KDC detection based on
'ads server' smb.conf parameter during ads_connect().

-- 
/ Alexander Bokovoy
$ cat /proc/identity >~/.signature
  `Senior software developer and analyst for SaM-Solutions Ltd.`
---
Nov 21 20:58:58 alconost kernel: VFS: Busy inodes after unmount. 
		    Self-destruct in 5 seconds.  Have a nice day...
-------------- next part --------------
Index: winbindd_ads.c
===================================================================
RCS file: /cvsroot/samba/source/nsswitch/winbindd_ads.c,v
retrieving revision 1.31
diff -u -r1.31 winbindd_ads.c
--- winbindd_ads.c	19 Dec 2001 08:44:22 -0000	1.31
+++ winbindd_ads.c	19 Dec 2001 11:24:29 -0000
@@ -116,11 +116,11 @@
 	unlink(ccache);
 
 	if (!resolve_name(domain->name, &server_ip, 0x1b)) {
-		DEBUG(1,("Can't find PDC for domain %s\n", domain->name));
-		return NULL;
-	}
+		DEBUG(1,("Warning: Can't find PDC for domain %s\n", domain->name));
+		ads = ads_init(NULL, NULL,NULL, NULL);
+	} else
+		ads = ads_init(primary_realm, inet_ntoa(server_ip), NULL, NULL);
 
-	ads = ads_init(primary_realm, inet_ntoa(server_ip), NULL, NULL);
 	if (!ads) {
 		DEBUG(1,("ads_init for domain %s failed\n", domain->name));
 		return NULL;


More information about the samba-technical mailing list