Bug 1329563 - Remove DLL blocklist checks for Windows XP. r?aklotz draft
authorChris Peterson <cpeterson@mozilla.com>
Sun, 08 Jan 2017 20:55:05 -0800
changeset 457510 0bab67a15de46d6623269d09f7f23117e2eda0f7
parent 457446 d192a99be4b436f2dc839435319f7630d5d8f4b0
child 541500 3e49c1fa7d5f05b477ea1aa76863c428d7532cf6
push id40799
push usercpeterson@mozilla.com
push dateMon, 09 Jan 2017 04:55:45 +0000
reviewersaklotz
bugs1329563
milestone53.0a1
Bug 1329563 - Remove DLL blocklist checks for Windows XP. r?aklotz MozReview-Commit-ID: 3zZDsjQii3o
mozglue/build/WindowsDllBlocklist.cpp
--- a/mozglue/build/WindowsDllBlocklist.cpp
+++ b/mozglue/build/WindowsDllBlocklist.cpp
@@ -63,22 +63,21 @@ struct DllBlockInfo {
   //
   // If the USE_TIMESTAMP flag is set, then we use the timestamp from
   // the IMAGE_FILE_HEADER in lieu of a version number.
   unsigned long long maxVersion;
 
   enum {
     FLAGS_DEFAULT = 0,
     BLOCK_WIN8PLUS_ONLY = 1,
-    BLOCK_XP_ONLY = 2,
     USE_TIMESTAMP = 4,
   } flags;
 };
 
-static DllBlockInfo sWindowsDllBlocklist[] = {
+static const DllBlockInfo sWindowsDllBlocklist[] = {
   // EXAMPLE:
   // { "uxtheme.dll", ALL_VERSIONS },
   // { "uxtheme.dll", 0x0000123400000000ULL },
   // The DLL name must be in lowercase!
   // The version field is a maximum, that is, we block anything that is
   // less-than or equal to that version.
 
   // NPFFAddon - Known malware
@@ -152,19 +151,16 @@ static DllBlockInfo sWindowsDllBlocklist
 
   // bug 812683 - crashes in Windows library when Asus Gamer OSD is installed
   // Software is discontinued/unsupported
   { "atkdx11disp.dll", ALL_VERSIONS },
 
   // Topcrash with Conduit SearchProtect, bug 944542
   { "spvc32.dll", ALL_VERSIONS },
 
-  // XP topcrash with F-Secure, bug 970362
-  { "fs_ccf_ni_umh32.dll", MAKE_VERSION(1, 42, 101, 0), DllBlockInfo::BLOCK_XP_ONLY },
-
   // Topcrash with V-bates, bug 1002748 and bug 1023239
   { "libinject.dll", UNVERSIONED },
   { "libinject2.dll", 0x537DDC93, DllBlockInfo::USE_TIMESTAMP },
   { "libredir2.dll", 0x5385B7ED, DllBlockInfo::USE_TIMESTAMP },
 
   // Crashes with RoboForm2Go written against old SDK, bug 988311/1196859
   { "rf-firefox-22.dll", ALL_VERSIONS },
   { "rf-firefox-40.dll", ALL_VERSIONS },
@@ -668,21 +664,16 @@ patched_LdrLoadDll (PWCHAR filePath, PUL
     printf_stderr("LdrLoadDll: info->name: '%s'\n", info->name);
 #endif
 
     if ((info->flags == DllBlockInfo::BLOCK_WIN8PLUS_ONLY) &&
         !IsWin8OrLater()) {
       goto continue_loading;
     }
 
-    if ((info->flags == DllBlockInfo::BLOCK_XP_ONLY) &&
-        IsWin2003OrLater()) {
-      goto continue_loading;
-    }
-
     unsigned long long fVersion = ALL_VERSIONS;
 
     if (info->maxVersion != ALL_VERSIONS) {
       ReentrancySentinel sentinel(dllName);
       if (sentinel.BailOut()) {
         goto continue_loading;
       }
 
@@ -741,17 +732,17 @@ continue_loading:
     // Check to ensure that the DLL has ASLR.
     full_fname = getFullPath(filePath, fname);
     if (!full_fname) {
       // uh, we couldn't find the DLL at all, so...
       printf_stderr("LdrLoadDll: Blocking load of '%s' (SearchPathW didn't find it?)\n", dllName);
       return STATUS_DLL_NOT_FOUND;
     }
 
-    if (IsVistaOrLater() && !CheckASLR(full_fname.get())) {
+    if (!CheckASLR(full_fname.get())) {
       printf_stderr("LdrLoadDll: Blocking load of '%s'.  XPCOM components must support ASLR.\n", dllName);
       return STATUS_DLL_NOT_FOUND;
     }
   }
 
   return stub_LdrLoadDll(filePath, flags, moduleFileName, handle);
 }