Hi, I was investigating this and I believe there is actually a way with Python but the problem is that the Python module with the binding is not being compiled (sorry but I have no idea why).
There should be a module called samba.dcerpc.srvsvc. If you look at librpc/gen_ndr/py_srvsvc.c you will find NetShareEnumAll which binds to the same function that's called when -L is used in smbclient. Maybe it's something with the make file? On Sun, Aug 16, 2009 at 4:36 PM, Igor Katson<[email protected]> wrote: > Helmut Hullen wrote: >> >> Hallo, Igor, >> >> Du meintest am 16.08.09: >> >> >>> >>> Is it possible to list samba shares and their contents of a >>> particular host? -- >>> >> >> Shell: >> >> smbclient -N -L $particular_host >> >> shows first all shares of that particular host and then some other stuff. >> Perhaps you filter some output depending on the key word "Disk" (or >> "Printer"). >> >> Contents: "that depends". >> You must have some rights. >> >> Viele Gruesse! >> Helmut >> > > Thanks. > Yes, I know of that shell command, but I would like to do that directly from > python for more flexibility, control and convenience. > -- > To unsubscribe from this list go to the following URL and read the > instructions: https://lists.samba.org/mailman/options/samba > -- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/options/samba
