libsmbclient for Samba4: initial design issues

Jelmer Vernooij jelmer at
Tue Oct 31 23:46:53 GMT 2006

Hi Derrell,

On Fri, 2005-08-12 at 15:25 -0400, derrell at wrote:
> I have been working on an initial design of libsmbclient for Samba4.  My
> goals for this design are as follows:
>  - Provide the full capability of the "raw" interface in Samba4.

>  - Add a layer on top of the "raw" interface that provides "simpler" usage
>    than the "raw" interface provides.  This layer will be along the lines of
>    the current Samba4 libcli/* functions, which use a "typical" set of
>    parameters to each of the functions to make them easier to use.  A mix of
>    these higher-level functions and the "raw" functions will work.
What's wrong with the current "raw" interface - we're currently already installing that as a shared library, and I don't see why we'd need a wrapper around it.

>  - Allow for an asynchronous interface with event notification.
>  - Keep the interface "pure"; i.e. no global or static variables.  Handles
>    (context variables, if you like) will be allocated and passed into each of
>    the functions.  This "may" allow the client library to be thread safe,
>    depending upon on what lies beneath it, but also meets the documented goals
>    of Samba4 and provides a clean interface.
>  - Ensure that a backwards compatibility layer is available, for easy
>    transition by users of Samba3's libsmbclient.  The backwards compatibility
>    layer provides the POSIX-like functions called smbc_*() in Samba3.
>    Clearly, the POSIX backwards compatibility layer will not meet the "pure"
>    goal, as this interface does not pass handles about, but must remain
>    backward compatible.  This layer can, I believe, isolate the non-pure state
>    information solely to its own code.)
I think this last bit is what libsmbclient in Samba 4 should be - all the other stuff is already there and already being installed (if you're building with shared library support). 


Jelmer Vernooij <jelmer at> -
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url :

More information about the samba-technical mailing list