is "net rpc share" (i.e. NetrShareEnum) clipping share names to 8
dave-gnus at bfnet.com
Wed Sep 8 22:25:52 GMT 2004
>> > My app needs to query Windows hosts using the NetrShareEnum RPC. It
>> > isn't obvious from the docs whether I can accomplish this with
>> > the smbclient app or the libsmbclient.so library. Is this
>> > implemented? Where is the API documented?
>> Nowhere, actually :)
Richard> Well, it would be easier if the libsmbclient (or libsmb) code
Richard> would call this function at the appropriate point, but it
Richard> doesn't as far as I am aware.
I notice that the "net" program has an interface to NetrShareEnum.
I've been playing with it, and it works, sorta.
It seems like share names are getting clipped by the net program to 8
bytes, but I haven't figured out where or why.
Currently the rpc_client code that the net program links to is only
output as a statically linkable object (libmsrpc.a). Will this ever
Richard> This will be much easier in Samba4, I suspect.
As far as incorporating the NetrShareEnum RPC into my own program in
the shortest time possible, should I try to use the code in libmsrpc,
or should I try to get Samba4 and use it?
More information about the samba-technical