[Samba] smbclient & server list
Gamid Isayev
gamid at isayev.net
Thu Sep 12 21:41:41 GMT 2002
I'm using smbclient to obtain server list for particular workgroup/domain.
Let say 'testserv1' is master browser for domain 'TEST', so command is:
smbclient -L testserv1 -U%
It works fine with Samba 2.2.3a:
Sharename Type Comment
--------- ---- -------
Error returning browse list: ERRDOS - ERRnoaccess (Access denied.)
Server Comment
--------- -------
LAB-PC
NET-APP-01
NET-APP-02
TESTSERV1
SQLSERV
Workgroup Master
--------- -------
ENGTEST ENGTEST1
TEST TESTSERV1
But when I installed Samba 3.0 alpha19, it breaks:
Sharename Type Comment
--------- ---- -------
Error returning browse list: NT_STATUS_ACCESS_DENIED
Server Comment
--------- -------
Workgroup Master
--------- -------
I checked what is in the NetServerEnum request packet and only
difference is Samba 2.2.3a sends request to port 139, but Samba 3.0
alpha19 sends request to port 445.
Then I set iptables to block outgoing connections to port 445, so Samba
3.0 alpha19 can't send request to port 445 and it forces Samba to send
request to port 139. After this Samba shows server list.
Questions:
1) how I can force smbclient to send request to port 139 using command
line options or smb.conf?
2) any other way to obtain server list?
More information about the samba
mailing list