Steve Langasek <[EMAIL PROTECTED]> writes: > For the purposes of getting a browse list, connecting to port 139 is a > must. There are ways to get the equivalent of a browse list via AD, but > I don't think it's LDAP-only, so port 445 doesn't even do any good in > this regard. > > For the actual enumeration of and connecting to shares, port 445 is > likely to give some performance increase due to the lower protocol > overhead. You can also configure newer Windows machines (XP at least) to > *not* support NetBIOS at all, in which case they'll only be listening on > port 445. OTOH, there are also plenty of older machines (NT4 and below) > that are 139-only.
If an XP or other "new" machine is configured to not support port 139, and it becomes a master browser then how would one get the browse list? > Theoretically, it might be optimal to use port 139 to collect browse > lists, and then use 445-else-139 for everything else. Barring that, I > think 139-else-445 would be the best option. This may be possible to do. The function where cli_initialize() and cli_connect() are called, is passed a server name and a share name. The share name seems to be IPC$ for every call I've seen into here, but is likely a "real" share name when opening a regular file. I have occasionally seen a server name of IPC$ as well. I suppose I could trace and determine which case is caused by which type of enumeration. Do you know offhand in which case(s) of server and share names I'm looking for a browse list? What if I do 139-else-445 if share is IPC$, and do 445-else-139 otherwise? Thanks, Derrell