From 128e7edaaf7cf6ed590c8b7260303520f7b773a0 Mon Sep 17 00:00:00 2001 From: Gerald Carter Date: Fri, 14 Mar 2003 23:06:06 +0000 Subject: fix WinXP & Win2K3 remote_arch and check pointer in ntlmssp code before dereferencing (This used to be commit 7bc5fc729f67ae16e09ea67efa9e2b8e2ba41c8f) --- source3/lib/util.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'source3/lib') diff --git a/source3/lib/util.c b/source3/lib/util.c index 8d62db5ebb..77ffa70a47 100644 --- a/source3/lib/util.c +++ b/source3/lib/util.c @@ -1740,6 +1740,22 @@ BOOL is_myworkgroup(const char *s) return(ret); } +/******************************************************************* + we distinguish between 2K and XP by the "Native Lan Manager" string + WinXP => "Windows 2002 5.1" + Win2k => "Windows 2000 5.0" + NT4 => "Windows NT 4.0" + Win9x => "Windows 4.0" +********************************************************************/ + +void ra_lanman_string( const char *native_lanman ) +{ + if ( 0 == strcmp( native_lanman, "Windows 2002 5.1" ) ) + set_remote_arch( RA_WINXP ); + else if ( 0 == strcmp( native_lanman, "Windows .NET 5.2" ) ) + set_remote_arch( RA_WIN2K3 ); +} + /******************************************************************* Set the horrid remote_arch string based on an enum. ********************************************************************/ -- cgit