vote / opinions required on rpcclient

Todd Sabin tastas at home.com
Sat Nov 27 20:47:58 GMT 1999


Luke Leighton <lkcl at samba.org> writes:

> i need to know whether people think it would be a good idea to retire
> rpcclient in favour of the following command suite:
> 
> net
> usrmgr
> srvmgr
> regedit
> eventvwr
> cmdat
> 
> basically, a suite of programs that match nt's .EXE equivalents.
> 

If you're going to be putting major effort into rpcclient, I'd love
to see the following:

Create a higher level libsmb (or maybe just add to libsmb?) which
contains the rpc level commands that rpcclient will use, and then
write rpcclient so that it uses only that library.  I've wanted to be
able to write progs something like:

#include <msrpc.h>
#include <samapi.h>
#include <lsaapi.h>

main ()
{
        SMB conn;
        SAM_HANDLE sam;
        SAM_HANDLE dom;

        rc = smb_connect (host, credentials..., &conn);

        rc = sam_connect (conn, &sam);

        rc = sam_open_domain (&sam, domainsid, MAX_ALLOWED, &dom);

        // etc.

        sam_close_handle (&dom);
        sam_close_handle (&sam);
}


but doing that currently means getting involved in lots of lower level
stuff that could be hidden in most cases.  Basically, I'd like to be
able to use the same set of RPC apis that are available on NT, with
some minor flexibility improvements (primarily the ability to use
multiple sets of credentials against the same host).

This would also allow other people to write net, usrmgr, srvmgr,
whatever else, much easier.  A gnome regedit would be pretty
straightforward to write, etc.


Todd


More information about the samba-technical mailing list