API to samba

Seb James seb at hypercubesystems.co.uk
Wed Jan 14 12:05:34 GMT 2004


Hi Folks,

I'm wanting to get some group and user info from a windows network. I'm
hoping that I can obtain this from samba via an API. 

I have 2 boxes; one the Primary Domain Controller and box 2, which is
running my application, in which I would like to know group and user
info from the PDC.

There is account info on the Windows NT primary domain controller.

Now, I understand from the samba howto collection, that I can't run
samba as a backup domain controller to the NT pdc. So, I will swap the
NT PDC to being a Samba PDC, so that my box 2 can now run Samba as a
backup domain controller.

Do I have any alternative to swapping the NT PDC for a Samba PDC? i.e.
can Samba get any user or group info from an NT PDC?

Now that I have my box number 2 running a samba backup domain controller
which therefore holds the group and user info, I would like to query it
through an API for the following info:

Either:

1) I have a client's IP number, and would like the user who is logged
into that client and that user's group.

2) I have a username and would like to obtain the user's group.

If I can do 1) I'll be happy, if not, then 2) would be sufficient info.

Can I get this info into my application via a Samba API?

Thanks in advance for any help.

Seb James




More information about the samba-technical mailing list