2.2 byte order problem while reading SID info?

Jeremy Allison jeremy at valinux.com
Tue Apr 17 17:06:24 GMT 2001

P Ranjit Kumar wrote:
> Hi All,
> I am playing around with supporting Samba 2.2 ACLs on HPUX 11.xx.
> Problem:
> When viewing permissions on a file from NT 4.0 explorer, NT shows SIDs
> instead
> of username and group name.
> Debugging status:
> I realized api_lsa_lookup_sids() is used to lookup SIDs on the Samba
> server. Down the function call graph, this function unmarshalls the
> SIDs from SMB buffer to DOM_SID structures.
> I debugged it a little more and realized that the sub_auths array in the
> structure isn't read in proper byteorder.
> So the SIDs aren't mapped to the names properly. When I run the same test
> against a 207 server, it shows proper names against the SIDs.
> I changed the smb_io_dom_sid function in 2.2 source so it reads the
> smb_auths
> array elements one by one (using prs_uint32) instead of reading all at a
> time
> (using prs_uint32s). Now 2.2 displays proper names instead of SIDs in the
> permissions window. So I am thinking, may be there is a problem with the
> way DBG_RW_PIVAL works in 2.2 (this macro is changed from 2.0.7).
> My question:
> Does anyone already know of this problem? Any fix available? I am already
> trying to see whats the change from 207 and what caused the problem.

What CVS version please ? I made the changes here to make
viewing SIDs work with Herb on IRIX within the last couple
of weeks (IRIX MIPS is also big-endian).

Can you ensure you're testing with the latest CVS please ?


Buying an operating system without source is like buying
a self-assembly Space Shuttle with no instructions.

More information about the samba-technical mailing list