1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-11 05:18:09 +03:00

r13382: added server affinity cache stores for 'net rpc join' and trusted domain code

(This used to be commit 9eb743584d)
This commit is contained in:
Gerald Carter 2006-02-08 04:03:47 +00:00 committed by Gerald (Jerry) Carter
parent 845e49bdab
commit f351b9c6eb
3 changed files with 13 additions and 0 deletions

View File

@ -210,6 +210,10 @@ static NTSTATUS domain_client_validate(TALLOC_CTX *mem_ctx,
return nt_status;
}
/* store a successful connection */
saf_store( domain, cli->desthost );
ZERO_STRUCT(info3);
/*

View File

@ -395,6 +395,11 @@ struct cli_state *net_make_ipc_connection(unsigned flags)
nt_status = connect_to_ipc(&cli, &server_ip, server_name);
}
/* store the server in the affinity cache if it was a PDC */
if ( flags & NET_FLAGS_PDC )
saf_store( cli->server_domain, cli->desthost );
SAFE_FREE(server_name);
if (NT_STATUS_IS_OK(nt_status)) {
return cli;

View File

@ -5541,6 +5541,10 @@ static int rpc_trustdom_establish(int argc, const char **argv)
nt_errstr(nt_status)));
return -1;
}
/* store who we connected to */
saf_store( domain_name, cli->desthost );
/*
* Connect to \\server\ipc$ again (this time anonymously)