Samba4 Patch: newuseradv and newgroupadv scripts for net cmd utlity

Lukasz Zalewski lukas at dcs.qmul.ac.uk
Tue Jun 8 03:43:28 MDT 2010


On 06/08/2010 08:11 AM, Matthias Dieter Wallnöfer wrote:
> Hi Lukasz,
>
> until now the policy was that "net group *"/"net user *" commands work
> over s4's "libnet". This doesn't seem to be the case here. Isn't this
> possible to fix - or is the binding missing?

Hi Matthias,
I wasn't aware of that policy ;) From the previous email conversation 
with Andrew, regarding moving newuser back to user set of subcommands, 
(and reinstating net rpc|ads|ldb hierarchy, to which andrew was 
against), i was under the impression that the underlying technology - it 
either being ldb or libnet should be hidden from the user and the best 
suited one should be chosen depending on the scenario

I'm still not sure what the criteria should be for choosing libnet over 
ldb (and vice versa)

as for libnet, I'm not very familiar with it, and i suspect some of the 
binding might not be adequate for the new options for group and newuser 
parameters ( i have not checked though so i might be completely off the 
mark here).
In the past i have never used the net utility for anything else but 
domain joining (i always operated on underlying ldap backend directly) 
so it was intuitive to start with ldb operations - i do agree that both 
libnet and ldb functionality should be present in the net cmd utilities


Regards

Luk
>
> Matthias
>
> Lukasz Zalewski wrote:
>> Hi Jelmer, all
>>
>> Attached is a new patch which is an extension to the previous newuser
>> functionality. It also adds the set of group commands (operating on
>> the ldb)
>>
>> Now, new user is created with CN='Firstname Initials. Lastname',<> if
>> any of them exists and --use-username-as-cn is not set (this is the AD
>> way) otherwise CN=username,<> is used
>> If --use-username-as-cn is defined then the user is created with
>> CN=username,<> even if any of (Firstname, Initials,Lastname) exist
>>
>> I also took liberty to add group set of subcommands, i.e.
>> /usr/local/samba/bin/net group
>> Available subcommands:
>> addmembers
>> add
>> removemembers
>> delete
>>
>> These only operate on ldb at the moment.
>>
>> Regards
>>
>> Luk
>



More information about the samba-technical mailing list