From 7ae555c43c55ab95f75fb4afdd3d2bcb403ad3b3 Mon Sep 17 00:00:00 2001 From: Gerald Carter Date: Fri, 14 Mar 2003 23:11:19 +0000 Subject: fix WinXP & Win2K3 remote_arch and check pointer in ntlmssp code before dereferencing (This used to be commit 2487480228b99183cab9e34ab497997e0c144ed6) --- 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