summaryrefslogtreecommitdiff
path: root/source3/rpc_client/cli_pipe.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2003-08-19 20:39:32 +0000
committerAndrew Bartlett <abartlet@samba.org>2003-08-19 20:39:32 +0000
commitf0cd6b35e551cdb2acb088f52edb0746da251b73 (patch)
tree6b4e672f4f5931d6c361b2023c35267d4e1cc6a1 /source3/rpc_client/cli_pipe.c
parent842b6e858314c4bd791ad203b51eeb463af4110d (diff)
downloadsamba-f0cd6b35e551cdb2acb088f52edb0746da251b73.tar.gz
samba-f0cd6b35e551cdb2acb088f52edb0746da251b73.tar.bz2
samba-f0cd6b35e551cdb2acb088f52edb0746da251b73.zip
- Fix the kerberos downgrade problem:
- When connecting to the NETOGON pipe, we make a call to auth2, in order to verify our identity. This call was being made with negotiation flags of 0x1ff. This caused our account to be downgraded. If we instead make the call with flags > 1ff (such as 0x701ff), then this does not occour. - This is *not* related to the use of kerberos for the CIFS-level connection My theory is that Win2k has a test to see if we are sending *exactly* what NT4 sent - setting any other flags seems to cause us to remain intact. Also ensure that we only have 'setup schannel' code in a few places, not scattered around cmd_netlogon too. Andrew Bartlett (This used to be commit e10f0529fe9d8d245b3cd001cce6a9a86896679c)
Diffstat (limited to 'source3/rpc_client/cli_pipe.c')
-rw-r--r--source3/rpc_client/cli_pipe.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source3/rpc_client/cli_pipe.c b/source3/rpc_client/cli_pipe.c
index 13a7841455..dedbf017a9 100644
--- a/source3/rpc_client/cli_pipe.c
+++ b/source3/rpc_client/cli_pipe.c
@@ -1493,7 +1493,9 @@ NTSTATUS cli_nt_establish_netlogon(struct cli_state *cli, int sec_chan,
const uchar trust_password[16])
{
NTSTATUS result;
- uint32 neg_flags = 0x000001ff;
+ /* The 7 here seems to be required to get Win2k not to downgrade us
+ to NT4. Actually, anything other than 1ff would seem to do... */
+ uint32 neg_flags = 0x000701ff;
int fnum;
cli_nt_netlogon_netsec_session_close(cli);
@@ -1586,6 +1588,8 @@ NTSTATUS cli_nt_setup_netsec(struct cli_state *cli, int sec_chan,
const uchar trust_password[16])
{
NTSTATUS result;
+ /* The 7 here seems to be required to get Win2k not to downgrade us
+ to NT4. Actually, anything other than 1ff would seem to do... */
uint32 neg_flags = 0x000701ff;
cli->pipe_auth_flags = 0;