VirtualBox

Ignore:
Timestamp:
Sep 10, 2014 7:54:42 PM (10 years ago)
Author:
vboxsync
Message:

SUP: relax trusted installer for winsxs too.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/Support/win/SUPHardenedVerifyImage-win.cpp

    r52634 r52690  
    10661066     * cheaper than the rest.
    10671067     *
    1068      * We relax this for system32, like we used to, as there are apparently
    1069      * some systems out there where the user, admin, or someone has changed the
    1070      * ownership of core windows DLLs like user32.dll.  Since we need user32.dll
    1071      * and will be checking it's digital signature, it's reasonably safe to let
    1072      * this thru. (The report was of SECURITY_BUILTIN_DOMAIN_RID + DOMAIN_ALIAS_RID_ADMINS
     1068     * We relax this for system32 and a little for WinSxS, like we used to, as
     1069     * there are apparently  some systems out there where the user, admin, or
     1070     * someone has changed the ownership of core windows DLLs like user32.dll
     1071     * and comctl32.dll.  Since we need user32.dll  and will be checking it's
     1072     * digital signature, it's reasonably safe to let this thru. (The report
     1073     * was of SECURITY_BUILTIN_DOMAIN_RID + DOMAIN_ALIAS_RID_ADMINS
    10731074     * owning user32.dll, see public ticket 13187, VBoxStartup.3.log.)
    10741075     *
     
    10771078     * that 3D got broken (mod by zero issue in test build 5).  These were also
    10781079     * SECURITY_BUILTIN_DOMAIN_RID + DOMAIN_ALIAS_RID_ADMINS.
     1080     *
     1081     * In one report by 'thor' the WinSxS resident comctl32.dll was owned by
     1082     * SECURITY_BUILTIN_DOMAIN_RID + DOMAIN_ALIAS_RID_ADMINS (with 4.3.16).
    10791083     */
    10801084    if (   (pNtViRdr->fFlags & SUPHNTVI_F_TRUSTED_INSTALLER_OWNER)
    10811085        && !supHardNtViCheckIsOwnedByTrustedInstallerOrSimilar(pNtViRdr->hFile, pwszName))
    10821086    {
    1083         if (!supHardViUtf16PathStartsWithEx(pwszName, (uint32_t)RTUtf16Len(pwszName),
    1084                                             g_System32NtPath.UniStr.Buffer, g_System32NtPath.UniStr.Length / sizeof(WCHAR),
    1085                                             true /*fCheckSlash*/))
     1087        if (supHardViUtf16PathStartsWithEx(pwszName, (uint32_t)RTUtf16Len(pwszName),
     1088                                           g_System32NtPath.UniStr.Buffer, g_System32NtPath.UniStr.Length / sizeof(WCHAR),
     1089                                           true /*fCheckSlash*/))
     1090            SUP_DPRINTF(("%ls: Relaxing the TrustedInstaller requirement for this DLL (it's in system32).\n", pwszName));
     1091        else if (supHardViUtf16PathStartsWithEx(pwszName, (uint32_t)RTUtf16Len(pwszName),
     1092                                                g_WinSxSNtPath.UniStr.Buffer, g_WinSxSNtPath.UniStr.Length / sizeof(WCHAR),
     1093                                                true /*fCheckSlash*/))
     1094            SUP_DPRINTF(("%ls: Relaxing the TrustedInstaller requirement for this DLL (it's in WinSxS).\n", pwszName));
     1095        else
    10861096            return RTErrInfoSetF(pErrInfo, VERR_SUP_VP_NOT_OWNED_BY_TRUSTED_INSTALLER,
    10871097                                 "supHardenedWinVerifyImageByHandle: TrustedInstaller is not the owner of '%ls'.", pwszName);
    1088         SUP_DPRINTF(("%ls: Relaxing the TrustedInstaller requirement for this DLL (it's in system32).\n", pwszName));
    10891098    }
    10901099
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette