[Samba] any reliable way to discover Windows hostname over SMB2+?
Jason Haar
jason_haar at trimble.com
Fri Jul 14 00:36:01 UTC 2017
On Fri, Jul 14, 2017 at 10:32 AM, Giulio via samba <samba at lists.samba.org>
wrote:
>
> It seems that kind of debug messages is gone even when using smb1 with
> newer smbclient versions.
>
>
Yes I noticed that too - even more motivation to find a different way
> ======
>
> rpcclient 3.x
> $ rpcclient -U "" -c srvinfo -N 192.168.1.171 -d 10 2>&1|grep AvNb|wc -l
> 0
>
> $ rpcclient -U wrong%wrong -c srvinfo -N 192.168.1.171 -d 10 2>&1
> |grep AvNb|wc -l
> 8 <== works
>
> rpcclient 4.7.0rc1 is like newer smbclient, the info is not there anymore.
>
Yes - unfortunately all that only works against Win7. Doesn't work on
Win2012 or Win10
>
> ========
>
> If you need this, I'd investigate using some kind of LLMNR client,
> since this is the "zeroconf" way to get Windows names: when you
> disable smb1 on Windows, netbios name resolution gets disabled too,
> and automatic name resolution is LLMNR only.
>
As far as I'm aware, LLMNR is multicast-only - which in practice means
broadcast-only? We've got a global WAN - over 200 sites. I can't rely on
broadcast/multicast - gotta be unicast.
Thanks for the help - you did some real digging there :-)
--
Cheers
Jason Haar
Information Security Manager, Trimble Navigation Ltd.
Phone: +1 408 481 8171
PGP Fingerprint: 7A2E 0407 C9A6 CAF6 2B9F 8422 C063 5EBB FE1D 66D1
More information about the samba
mailing list