Created attachment 10304 [details] fix for this problem winbind can crash when using the idmap_rfc2307 module and the call to ads_do_search_retry needs to establish a new connection to the DC. In that case, the local pointer to the LDAP server struct becomes invalid. The easiest fix is to update the local pointer after the call to ads_do_search_retry (see attached patch).
(In reply to comment #0) > Created attachment 10304 [details] > fix for this problem > > winbind can crash when using the idmap_rfc2307 module and the > call to ads_do_search_retry needs to establish a new connection > to the DC. In that case, the local pointer to the LDAP server > struct becomes invalid. The easiest fix is to update the > local pointer after the call to ads_do_search_retry (see attached > patch). Hi, Christof! There's a ton of calls like this. While your patch is very likely 100% correct, would it not be worthwhile to fix some more of that? The ads_*_search* interface just sucks badly :-(
(In reply to comment #1) > (In reply to comment #0) > > Created attachment 10304 [details] [details] > > fix for this problem > > > > winbind can crash when using the idmap_rfc2307 module and the > > call to ads_do_search_retry needs to establish a new connection > > to the DC. In that case, the local pointer to the LDAP server > > struct becomes invalid. The easiest fix is to update the > > local pointer after the call to ads_do_search_retry (see attached > > patch). > > Hi, Christof! > > There's a ton of calls like this. While your patch is very likely 100% correct, > would it not be worthwhile to fix some more of that? The ads_*_search* > interface just sucks badly :-( I agree, but as discussed yesterday, i think it is worthwhile to fix this bug first before attempting to improve the ads_* and ldap libraries.
Reassigning for inclusion in 4.1 stream.
Pushed to autobuild-v4-1-test.
Thanks you. When opening this bugzilla, i as not sure of the state of the 4.2 branch. This patch also needs to get into 4.2.
(In reply to Christof Schmitt from comment #5) Pushed to autobuild-v4-2-test.
(In reply to Karolin Seeger from comment #4) Pushed to v4-1-test. Waiting for autobuild-v4-2-test.
Pushed to bith branches. Closing out bug report. Thanks!
(In reply to Karolin Seeger from comment #8) both, of course... ;-)