CVS update: samba/source/passdb
Richard Sharpe
sharpe at ns.aus.com
Sun Nov 26 14:52:49 GMT 2000
At 10:36 PM 11/26/00 -0600, Gerald Carter wrote:
>Richard Sharpe wrote:
>>
>> Date: Monday November 27, 2000 @ 13:44
>> Author: sharpe
>>
>> Update of /data/cvs/samba/source/passdb
>> In directory samba:/tmp/cvs-serv14223
>>
>> Modified Files:
>> Tag: SAMBA_2_2
>> passdb.c
>> Log Message:
>> Ensure that we call Get_Pwnam so that workstation account
>> names are mapped to the correct case!
>>
>> Otherwise the doco has to change ...
>
>Richard,
>
>This is actually a big performance hit. Tim, we need to
>revist the dependencies here. Look at
>construct_default_printer_sdb()
OK, I admit that my patch was a knee-jerk to fix my problem, and can
understand that it is a problem in a situation where there are lots of
entries in the user database.
As a stop-gap, perhaps we should simply special case machine names for
2.2.0, and look for $ on the end of a name, and convert to lowercase when
we find it.
>if (!lookup_name( "Printer Administrators", &owner_sid, &name_type) &&
> !lookup_name( "Administrators", &owner_sid, &name_type) &&
> !lookup_name( "Administrator", &owner_sid, &name_type) &&
> !lookup_name("root", &owner_sid, &name_type)) {
> sid_copy(&owner_sid, &global_sid_World);
> }
>}
>
>This code (indirectly using local_lookup_name()) was making
>it impossible to print. I had a LDAP server providing about
>6,000 accounts. Simply trying to look at the printer
>properties was impossible because of the getpwnam() calls.
>local_lookup_name() need to use sys_getpwnam(). We should
>deal with machine accounts, but using Get_Pwnam() in
>local_lookup_name() has some fairly large implications.
>
>
>I'm open to suggestions, but I am really buried this week.
>
>
>
>
>
>
>Cheers, jerry
>----------------------------------------------------------------------
> /\ Gerald (Jerry) Carter Professional Services
> \/ http://www.valinux.com/ VA Linux Systems gcarter at valinux.com
> http://www.samba.org/ SAMBA Team jerry at samba.org
> http://www.plainjoe.org/ jerry at plainjoe.org
>
> "...a hundred billion castaways looking for a home."
> - Sting "Message in a Bottle" ( 1979 )
>
Regards
-------
Richard Sharpe, sharpe at ns.aus.com
Samba (Team member, www.samba.org), Ethereal (Team member, www.zing.org)
Contributing author, SAMS Teach Yourself Samba in 24 Hours
Author, Special Edition, Using Samba
More information about the samba-technical
mailing list