summaryrefslogtreecommitdiffstats
path: root/source/libsmb/clientgen.c
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>1998-12-14 21:22:59 +0000
committerLuke Leighton <lkcl@samba.org>1998-12-14 21:22:59 +0000
commitc2bcb3a286f22ed4f0f55da2a3eb2bff17906fb1 (patch)
tree0ce325bc8a8230c08ceb85c1346e0dfee2fe030f /source/libsmb/clientgen.c
parent0b2095e092d747f741e78a3349f0b81a72811629 (diff)
downloadsamba-c2bcb3a286f22ed4f0f55da2a3eb2bff17906fb1.tar.gz
samba-c2bcb3a286f22ed4f0f55da2a3eb2bff17906fb1.tar.xz
samba-c2bcb3a286f22ed4f0f55da2a3eb2bff17906fb1.zip
server_cryptkey() now calling cli_connectserverlist(). stupid microsoft
idiotic *SMBSERVER connectionism added to cli_connect_serverlist(). also added check for protocol < LANMAN2.
Diffstat (limited to 'source/libsmb/clientgen.c')
-rw-r--r--source/libsmb/clientgen.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/source/libsmb/clientgen.c b/source/libsmb/clientgen.c
index 99d868e216a..5bae8ffa81c 100644
--- a/source/libsmb/clientgen.c
+++ b/source/libsmb/clientgen.c
@@ -2728,7 +2728,7 @@ BOOL cli_connect_serverlist(struct cli_state *cli, char *p)
extern pstring scope;
fstring remote_machine;
struct in_addr dest_ip;
- struct nmb_name calling, called;
+ struct nmb_name calling, called, stupid_smbserver_called;
BOOL connected_ok = False;
/*
@@ -2763,19 +2763,28 @@ BOOL cli_connect_serverlist(struct cli_state *cli, char *p)
make_nmb_name(&calling, global_myname , 0x0 , scope);
make_nmb_name(&called , remote_machine, 0x20, scope);
+ /* stupid microsoft destruction of the ability of netbios
+ * to provide multiple netbios servers on one host.
+ */
+ make_nmb_name(&stupid_smbserver_called , "*SMBSERVER", 0x20, scope);
pwd_set_nullpwd(&cli->pwd);
if (!cli_establish_connection(cli, remote_machine, &dest_ip,
&calling, &called,
"IPC$", "IPC",
+ False, True) &&
+ !cli_establish_connection(cli, remote_machine, &dest_ip,
+ &calling, &stupid_smbserver_called,
+ "IPC$", "IPC",
False, True))
{
cli_shutdown(cli);
continue;
}
- if (!IS_BITS_SET_ALL(cli->sec_mode, 1))
+ if (cli->protocol < PROTOCOL_LANMAN2 ||
+ !IS_BITS_SET_ALL(cli->sec_mode, 1))
{
DEBUG(1,("cli_connect_serverlist: machine %s isn't in user level security mode\n",
remote_machine));