-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Русаков Денис wrote:
> Hello, all
>     I'd like to create, remove, change samba accounts, groups etc. from my 
> own C program.
>     How can I do this, without using samba tools, but some samba API (headers 
> and shared objects).
>     Does samba provide some API (headers and shared objects) for accounts 
> creating etc.?
> Thank you

Starting with Samba 3.2 we added a new shared library called libnetapi.
This library is designed very closely to the Windows NetApi equivalent,
and provides functions for all these tasks you are looking for.

For the upcoming Samba 3.3 release, this library provides around 50
calls and includes example code for at least all account management
functions.

You may want to have a look at:
NetUserAdd,
NetUserDel,
NetUserSetInfo,
and the the NetGroup* functions.

The header file is located under: $SRC/lib/netapi/netapi.h
Example code can found under: $SRC/lib/netapi/examples

Let us know where we can help further.

Hope this helps,
Guenther


- --
Günther Deschner                    GPG-ID: 8EE11688
Red Hat                         [EMAIL PROTECTED]
Samba Team                              [EMAIL PROTECTED]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org

iEYEARECAAYFAkjrKKkACgkQSOk3aI7hFojZNgCeLrPgVUfGQE/pzHgFpksAKzes
B54An0NQzodllYBnVnSMV8Ww5Jw1aLPj
=85Zy
-----END PGP SIGNATURE-----
-- 
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/listinfo/samba

Reply via email to