Index: /trunk/src/VBox/Runtime/r3/win/RTSystemQueryOSInfo-win.cpp
===================================================================
--- /trunk/src/VBox/Runtime/r3/win/RTSystemQueryOSInfo-win.cpp	(revision 70214)
+++ /trunk/src/VBox/Runtime/r3/win/RTSystemQueryOSInfo-win.cpp	(revision 70215)
@@ -191,4 +191,6 @@
                 case kRTWinOSType_98SE:         strcpy(szTmp, "Windows 98 (Second Edition)"); break;
                 case kRTWinOSType_ME:           strcpy(szTmp, "Windows Me"); break;
+                case kRTWinOSType_NT310:        strcpy(szTmp, "Windows NT 3.10"); break;
+                case kRTWinOSType_NT350:        strcpy(szTmp, "Windows NT 3.50"); break;
                 case kRTWinOSType_NT351:        strcpy(szTmp, "Windows NT 3.51"); break;
                 case kRTWinOSType_NT4:          strcpy(szTmp, "Windows NT 4.0"); break;
Index: /trunk/src/VBox/Runtime/r3/win/init-win.cpp
===================================================================
--- /trunk/src/VBox/Runtime/r3/win/init-win.cpp	(revision 70214)
+++ /trunk/src/VBox/Runtime/r3/win/init-win.cpp	(revision 70215)
@@ -222,5 +222,8 @@
         if (        dwMajorVersion == 3
                  && dwMinorVersion == 1)
-            enmVer = kRTWinOSType_NT31;
+            enmVer = kRTWinOSType_NT310;
+        else if (   dwMajorVersion == 3
+                 && dwMinorVersion == 50)
+            enmVer = kRTWinOSType_NT350;
         else if (   dwMajorVersion == 3
                  && dwMinorVersion == 51)
Index: /trunk/src/VBox/Runtime/r3/win/internal-r3-win.h
===================================================================
--- /trunk/src/VBox/Runtime/r3/win/internal-r3-win.h	(revision 70214)
+++ /trunk/src/VBox/Runtime/r3/win/internal-r3-win.h	(revision 70215)
@@ -56,5 +56,6 @@
     kRTWinOSType_9XLAST     = 99,
     kRTWinOSType_NTFIRST    = 100,
-    kRTWinOSType_NT31       = kRTWinOSType_NTFIRST,
+    kRTWinOSType_NT310      = kRTWinOSType_NTFIRST,
+    kRTWinOSType_NT350,
     kRTWinOSType_NT351,
     kRTWinOSType_NT4,
Index: /trunk/src/VBox/Runtime/r3/win/process-win.cpp
===================================================================
--- /trunk/src/VBox/Runtime/r3/win/process-win.cpp	(revision 70214)
+++ /trunk/src/VBox/Runtime/r3/win/process-win.cpp	(revision 70215)
@@ -141,4 +141,7 @@
 static PFNCREATEPROCESSWITHLOGON        g_pfnCreateProcessWithLogonW    = NULL;
 static PFNLSALOOKUPNAMES2               g_pfnLsaLookupNames2            = NULL;
+static decltype(LogonUserW)            *g_pfnLogonUserW                 = NULL;
+static decltype(CreateProcessAsUserW)  *g_pfnCreateProcessAsUserW       = NULL;
+static decltype(LsaNtStatusToWinError) *g_pfnLsaNtStatusToWinError      = NULL;
 /* userenv.dll: */
 static PFNCREATEENVIRONMENTBLOCK        g_pfnCreateEnvironmentBlock     = NULL;
@@ -345,8 +348,17 @@
     {
         rc = RTLdrGetSymbol(hMod, "CreateProcessWithLogonW", (void **)&g_pfnCreateProcessWithLogonW);
-        AssertStmt(RT_SUCCESS(rc), g_pfnCreateProcessWithLogonW = NULL);
+        if (RT_FAILURE(rc)) { g_pfnCreateProcessWithLogonW = NULL; Assert(g_enmWinVer <= kRTWinOSType_NT4); }
 
         rc = RTLdrGetSymbol(hMod, "LsaLookupNames2", (void **)&g_pfnLsaLookupNames2);
-        AssertStmt(RT_SUCCESS(rc), g_pfnLsaLookupNames2 = NULL);
+        if (RT_FAILURE(rc)) { g_pfnLsaLookupNames2 = NULL; Assert(g_enmWinVer <= kRTWinOSType_NT4); }
+
+        rc = RTLdrGetSymbol(hMod, "LogonUserW", (void **)&g_pfnLogonUserW);
+        if (RT_FAILURE(rc)) { g_pfnLogonUserW = NULL; Assert(g_enmWinVer <= kRTWinOSType_NT350); }
+
+        rc = RTLdrGetSymbol(hMod, "CreateProcessAsUserW", (void **)&g_pfnCreateProcessAsUserW);
+        if (RT_FAILURE(rc)) { g_pfnCreateProcessAsUserW = NULL; Assert(g_enmWinVer <= kRTWinOSType_NT350); }
+
+        rc = RTLdrGetSymbol(hMod, "LsaNtStatusToWinError", (void **)&g_pfnLsaNtStatusToWinError);
+        if (RT_FAILURE(rc)) { g_pfnLsaNtStatusToWinError = NULL; Assert(g_enmWinVer <= kRTWinOSType_NT350); }
 
         RTLdrClose(hMod);
@@ -360,14 +372,14 @@
     {
         rc = RTLdrGetSymbol(hMod, "LoadUserProfileW", (void **)&g_pfnLoadUserProfileW);
-        AssertStmt(RT_SUCCESS(rc), g_pfnLoadUserProfileW = NULL);
+        if (RT_FAILURE(rc)) { g_pfnLoadUserProfileW = NULL; Assert(g_enmWinVer <= kRTWinOSType_NT4); }
 
         rc = RTLdrGetSymbol(hMod, "UnloadUserProfile", (void **)&g_pfnUnloadUserProfile);
-        AssertStmt(RT_SUCCESS(rc), g_pfnUnloadUserProfile = NULL);
+        if (RT_FAILURE(rc)) { g_pfnUnloadUserProfile = NULL; Assert(g_enmWinVer <= kRTWinOSType_NT4); }
 
         rc = RTLdrGetSymbol(hMod, "CreateEnvironmentBlock", (void **)&g_pfnCreateEnvironmentBlock);
-        AssertStmt(RT_SUCCESS(rc), g_pfnCreateEnvironmentBlock = NULL);
+        if (RT_FAILURE(rc)) { g_pfnCreateEnvironmentBlock = NULL; Assert(g_enmWinVer <= kRTWinOSType_NT4); }
 
         rc = RTLdrGetSymbol(hMod, "DestroyEnvironmentBlock", (void **)&g_pfnDestroyEnvironmentBlock);
-        AssertStmt(RT_SUCCESS(rc), g_pfnDestroyEnvironmentBlock = NULL);
+        if (RT_FAILURE(rc)) { g_pfnDestroyEnvironmentBlock = NULL; Assert(g_enmWinVer <= kRTWinOSType_NT4); }
 
         RTLdrClose(hMod);
@@ -662,4 +674,6 @@
     AssertPtrReturn(pwszPassword, VERR_INVALID_POINTER);
     AssertPtrReturn(phToken,      VERR_INVALID_POINTER);
+    if (!g_pfnLogonUserW)
+        return VERR_NOT_SUPPORTED;
 
     /*
@@ -672,11 +686,11 @@
      */
     PCRTUTF16 pwszDomainNone = g_enmWinVer < kRTWinOSType_2K ? L"" /* NT4 and older */ : NULL /* Windows 2000 and up */;
-    BOOL fRc = LogonUserW(pwszUser,
-                          /* The domain always is passed as part of the UPN (user name). */
-                          pwszDomainNone,
-                          pwszPassword,
-                          LOGON32_LOGON_INTERACTIVE,
-                          LOGON32_PROVIDER_DEFAULT,
-                          phToken);
+    BOOL fRc = g_pfnLogonUserW(pwszUser,
+                               /* The domain always is passed as part of the UPN (user name). */
+                               pwszDomainNone,
+                               pwszPassword,
+                               LOGON32_LOGON_INTERACTIVE,
+                               LOGON32_PROVIDER_DEFAULT,
+                               phToken);
     if (fRc)
         return VINF_SUCCESS;
@@ -1530,9 +1544,14 @@
                             }
                         }
+                        else if (g_pfnLsaNtStatusToWinError)
+                        {
+                            dwErr = g_pfnLsaNtStatusToWinError(ntSts);
+                            LogRelFunc(("LsaLookupNames2 failed with: %ld\n", dwErr));
+                            rc = dwErr != NO_ERROR ? RTErrConvertFromWin32(dwErr) : VERR_INTERNAL_ERROR_2;
+                        }
                         else
                         {
-                            dwErr = LsaNtStatusToWinError(ntSts);
-                            LogRelFunc(("LsaLookupNames2 failed with: %ld\n", dwErr));
-                            rc = dwErr != NO_ERROR ? RTErrConvertFromWin32(dwErr) : VERR_INTERNAL_ERROR_2;
+                            LogRelFunc(("LsaLookupNames2 failed with: %#x\n", ntSts));
+                            rc = RTErrConvertFromNtStatus(ntSts);
                         }
 
@@ -1551,9 +1570,14 @@
                         LsaClose(lsahPolicy);
                     }
+                    else if (g_pfnLsaNtStatusToWinError)
+                    {
+                        dwErr = g_pfnLsaNtStatusToWinError(ntSts);
+                        LogRelFunc(("LsaOpenPolicy failed with: %ld\n", dwErr));
+                        rc = dwErr != NO_ERROR ? RTErrConvertFromWin32(dwErr) : VERR_INTERNAL_ERROR_3;
+                    }
                     else
                     {
-                        dwErr = LsaNtStatusToWinError(ntSts);
-                        LogRelFunc(("LsaOpenPolicy failed with: %ld\n", dwErr));
-                        rc = dwErr != NO_ERROR ? RTErrConvertFromWin32(dwErr) : VERR_INTERNAL_ERROR_3;
+                        LogRelFunc(("LsaOpenPolicy failed with: %#x\n", ntSts));
+                        rc = RTErrConvertFromNtStatus(ntSts);
                     }
 
@@ -1696,27 +1720,32 @@
                                  *      http://support.microsoft.com/kb/327618/
                                  */
-                                fRc = CreateProcessAsUserW(hTokenToUse,
-                                                           *ppwszExec,
-                                                           pwszCmdLine,
-                                                           NULL,         /* pProcessAttributes */
-                                                           NULL,         /* pThreadAttributes */
-                                                           TRUE,         /* fInheritHandles */
-                                                           dwCreationFlags,
-                                                           /** @todo Warn about exceeding 8192 bytes
-                                                            *        on XP and up. */
-                                                           pwszzBlock,   /* lpEnvironment */
-                                                           NULL,         /* pCurrentDirectory */
-                                                           pStartupInfo,
-                                                           pProcInfo);
-                                if (fRc)
-                                    rc = VINF_SUCCESS;
+                                if (g_pfnCreateProcessAsUserW)
+                                {
+                                    fRc = g_pfnCreateProcessAsUserW(hTokenToUse,
+                                                                    *ppwszExec,
+                                                                    pwszCmdLine,
+                                                                    NULL,         /* pProcessAttributes */
+                                                                    NULL,         /* pThreadAttributes */
+                                                                    TRUE,         /* fInheritHandles */
+                                                                    dwCreationFlags,
+                                                                    /** @todo Warn about exceeding 8192 bytes
+                                                                     *        on XP and up. */
+                                                                    pwszzBlock,   /* lpEnvironment */
+                                                                    NULL,         /* pCurrentDirectory */
+                                                                    pStartupInfo,
+                                                                    pProcInfo);
+                                    if (fRc)
+                                        rc = VINF_SUCCESS;
+                                    else
+                                    {
+                                        dwErr = GetLastError();
+                                        if (dwErr == ERROR_PRIVILEGE_NOT_HELD)
+                                            rc = rtProcWinFigureWhichPrivilegeNotHeld2();
+                                        else
+                                            rc = RTErrConvertFromWin32(dwErr);
+                                    }
+                                }
                                 else
-                                {
-                                    dwErr = GetLastError();
-                                    if (dwErr == ERROR_PRIVILEGE_NOT_HELD)
-                                        rc = rtProcWinFigureWhichPrivilegeNotHeld2();
-                                    else
-                                        rc = RTErrConvertFromWin32(dwErr);
-                                }
+                                    rc = VERR_NOT_SUPPORTED;
 
                                 if (hOldWinStation)
