Hello.
I have searched net for this information and I could find solution for my problems. I'm writing a perl script which searches local network for computers with windows shares.
I have done this by executing  nmblookup -M -- -
From this command I get a list of  computer (by ip) with MSBROWSE.
Then I'm using smbclient command to get shares from every ip.
I have one problem to solve.
How I can check if share needs password and user ?
Which command tool use to examine if shares need authentication.
Now I use mount option with user=% it works for servers without password.
If mount is not successful I read error and prompt for password.
But this is ugly solution. I have one server which can be mounted with user=% but mounted shares are avaliable only for root user.
If I mount it with user and password everything works.
Maybe this is silly question but I can't find command tool for checking if password is needed.
Thank in advance.

--
Pozdrawiam/Kind regards

Tomasz Kobiela


--
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba

Reply via email to