svn commit: samba r7730 - branches/SAMBA_3_0/source/passdb
trunk/source/passdb
vlendec at samba.org
vlendec at samba.org
Sat Jun 18 16:47:28 GMT 2005
Author: vlendec
Date: 2005-06-18 16:47:27 +0000 (Sat, 18 Jun 2005)
New Revision: 7730
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=7730
Log:
Some merges
Modified:
branches/SAMBA_3_0/source/passdb/passdb.c
trunk/source/passdb/passdb.c
Changeset:
Modified: branches/SAMBA_3_0/source/passdb/passdb.c
===================================================================
--- branches/SAMBA_3_0/source/passdb/passdb.c 2005-06-18 16:31:48 UTC (rev 7729)
+++ branches/SAMBA_3_0/source/passdb/passdb.c 2005-06-18 16:47:27 UTC (rev 7730)
@@ -832,8 +832,6 @@
gid = pdb_group_rid_to_gid(rid);
gr = getgrgid(gid);
- *psid_name_use = SID_NAME_ALIAS;
-
DEBUG(5,("local_lookup_sid: looking up gid %u %s\n", (unsigned int)gid,
gr ? "succeeded" : "failed" ));
@@ -1223,24 +1221,6 @@
}
/****************************************************************************
- Convert a gid to SID - algorithmic.
-****************************************************************************/
-
-DOM_SID *algorithmic_gid_to_sid(DOM_SID *psid, uid_t gid)
-{
- if ( !lp_enable_rid_algorithm() )
- return NULL;
-
- DEBUG(8,("algorithmic_gid_to_sid: falling back to RID algorithm\n"));
- sid_copy( psid, get_global_sam_sid() );
- sid_append_rid( psid, pdb_gid_to_group_rid(gid) );
- DEBUG(10,("algorithmic_gid_to_sid: gid (%d) -> SID %s.\n",
- (unsigned int)gid, sid_string_static(psid) ));
-
- return psid;
-}
-
-/****************************************************************************
Convert a gid to SID - locally.
****************************************************************************/
@@ -1260,14 +1240,16 @@
if ( !ret ) {
- /* algorithmic to rid mapping if enabled */
+ /* fallback to rid mapping if enabled */
if ( lp_enable_rid_algorithm() ) {
+ sid_copy(psid, get_global_sam_sid());
+ sid_append_rid(psid, pdb_gid_to_group_rid(gid));
DEBUG(10,("local_gid_to_sid: Fall back to algorithmic mapping: %u -> %s\n",
(unsigned int)gid, sid_string_static(psid)));
- return algorithmic_gid_to_sid(psid, gid);
+ return psid;
}
else
return NULL;
Modified: trunk/source/passdb/passdb.c
===================================================================
--- trunk/source/passdb/passdb.c 2005-06-18 16:31:48 UTC (rev 7729)
+++ trunk/source/passdb/passdb.c 2005-06-18 16:47:27 UTC (rev 7730)
@@ -1297,7 +1297,7 @@
}
if (!sid_peek_rid(psid, &rid)) {
- DEBUG(10,("local_sid_to_uid: invalid SID!\n"));
+ DEBUG(10,("local_sid_to_gid: invalid SID!\n"));
return False;
}
More information about the samba-cvs
mailing list