[SCM] Samba Shared Repository - branch v3-6-test updated

Karolin Seeger kseeger at samba.org
Tue Jun 14 11:43:54 MDT 2011

The branch, v3-6-test has been updated
       via  bad9f47 bug in source3/winbindd/winbindd_sids_to_xids.c
      from  531edfd s3-winbind: Fix paranoia checks in winbindd_samr.c.


- Log -----------------------------------------------------------------
commit bad9f4781133583811420768ebcea9a28597cb7a
Author: Herb Lewis <hlewis at panasas.com>
Date:   Thu Jun 9 23:17:11 2011 -0700

    bug in source3/winbindd/winbindd_sids_to_xids.c
    I'm having trouble getting my system setup to do submits right now but
    I discovered a bug in the subject file that causes winbindd lookup sids
    command to assign incorrect unix ids. The change to sid_peek_rid fixes
    the case where you call lookup sids with sids s1 s2 s3 which cause them
    to be cached. then call with s1 s2 s4 and s4 will get the unix id of s1.
    The other change fixes the case where a sid that was not translated
    gets a value returned instead of being listed as unmapped.
    Could someone review this and push to master and 3.6 for me?
    Fix bug #8216 (winbind returns wrong results with sids2xids).


Summary of changes:
 source3/winbindd/winbindd_sids_to_xids.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

Changeset truncated at 500 lines:

diff --git a/source3/winbindd/winbindd_sids_to_xids.c b/source3/winbindd/winbindd_sids_to_xids.c
index 68616fa..9c38b5a 100644
--- a/source3/winbindd/winbindd_sids_to_xids.c
+++ b/source3/winbindd/winbindd_sids_to_xids.c
@@ -201,7 +201,7 @@ static void winbindd_sids_to_xids_lookupsids_done(struct tevent_req *subreq)
 		t->domain_index = n->sid_index;
-		sid_peek_rid(&state->sids[i], &t->rid);
+		sid_peek_rid(&state->non_cached[i], &t->rid);
 		t->unix_id = (uint64_t)-1;
@@ -268,6 +268,9 @@ NTSTATUS winbindd_sids_to_xids_recv(struct tevent_req *req,
 		} else {
 			unix_id = state->ids.ids[num_non_cached].unix_id;
+			if (unix_id == -1) {
+				found = false;
+			}
 			switch(state->ids.ids[num_non_cached].type) {
 			case WBC_ID_TYPE_UID:
 				type = 'U';

Samba Shared Repository

More information about the samba-cvs mailing list