broken string_to_sid, sid_to_string

Jeremy Allison jallison at cthulhu.engr.sgi.com
Wed Nov 25 19:25:40 GMT 1998


Luke Kenneth Casson Leighton wrote:

> as the string_to_sid() functions are broken, there is an opportunity _now_
> to fix them even more proplerly.
> 
> these functions read the rid components in decimal, they should not: they
> should read in hex.
> 
> can we fix this?

No and here's why - backwards compatibility.

Imagine the case where someone has a Samba 2.0
server in an NT domain. It stores it's local machine
SID in the MACHINE.SID file, in the current format.

We bring out 2.1, and you have changed the default
for reading the rid components from the file. 

Suprise (for the Samba admins, anyway :-) - they're no
longer in the domain. This is a *BAD* thing.

For backwards compatibilities sake, we *have* to
add the 0x prefix for reading in hex. Sorry, but
we have too many users now.

Just more ammo for the "think before we code"
brigade. BTW: You and I don't do that *ENOUGH*.

Jeremy.

-- 
--------------------------------------------------------
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