[Samba] Re: Samba PDC migration - success!

Tim Allen timallen at dcallen.co.uk
Mon Jul 22 04:26:02 GMT 2002


Andrew Bartlett wrote:

> > (BTW, the typecast on the return value in pdb_user_rid_to_gid() needs
> > changing).
>
> Patch please?  (That way I see exactly what you mean).

--- passdb.c.old        Mon Jul 22 12:10:58 2002
+++ passdb.c    Mon Jul 22 12:12:34 2002
@@ -413,7 +413,7 @@

 gid_t pdb_user_rid_to_gid(uint32 user_rid)
 {
-       return (uid_t)(((user_rid & (~GROUP_RID_TYPE))-
1000)/RID_MULTIPLIER);
+       return (gid_t)(((user_rid & (~GROUP_RID_TYPE))-
1000)/RID_MULTIPLIER);
 }


> > I do have a question:
> >
> > I'm assuming there's no mapping issues with the GID's and it is OK to
shift
> > these. Is that the case or is there a potential problem there?
>
> Yes, there is a problem.  Any files on the client with ACLs or owners
> that are groups will not resolve if you change the group's RID.  Users
> may be unable to access files on the clients.

Fortunately I don't think that's an issue for us. At first I was going to
strip the bit off both types but realized that pdb_rid_is_user() used it.

Tim Allen





More information about the samba mailing list