Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)

Merge pull request #15762 (Chromium update)

This is the original pull request plus some commits from me to bring all
channels to the latest versions, because the fixed security
vulnerabilites might not be fixed in the dev version we had before.

I've tested the whole changeset on my Hydra at:

https://headcounter.org/hydra/eval/322006

Thanks to @srp for the initial commit and thus implicitly also for the
security notice.

Cc: @abbradar
(backported from commit b5f95a5303a4bf20b513c2a4f636b82cb588239a)
Reason: Lots of security fixes (see e2d067d)

aszlig a3521b60 4f32d2c5

Changed files
+31 -57
pkgs
applications
+11 -18
pkgs/applications/networking/browsers/chromium/common.nix
··· 56 56 use_system_flac = true; 57 57 use_system_libevent = true; 58 58 use_system_libexpat = true; 59 - use_system_libjpeg = true; 60 - use_system_libpng = versionOlder upstream-info.version "51.0.0.0"; 59 + # XXX: System libjpeg fails to link for version 52.0.2743.10 60 + use_system_libjpeg = upstream-info.version != "52.0.2743.10"; 61 + use_system_libpng = false; 61 62 use_system_libwebp = true; 62 63 use_system_libxml = true; 63 64 use_system_opus = true; ··· 123 124 ++ optionals gnomeSupport [ gnome.GConf libgcrypt ] 124 125 ++ optional enableSELinux libselinux 125 126 ++ optionals cupsSupport [ libgcrypt cups ] 126 - ++ optional pulseSupport libpulseaudio 127 - ++ optional (versionOlder version "51.0.0.0") libexif; 127 + ++ optional pulseSupport libpulseaudio; 128 128 129 129 patches = [ 130 - ./patches/build_fixes_46.patch 131 130 ./patches/widevine.patch 132 - (if versionOlder version "50.0.0.0" 133 - then ./patches/nix_plugin_paths_46.patch 134 - else ./patches/nix_plugin_paths_50.patch) 131 + (if versionOlder version "52.0.0.0" 132 + then ./patches/nix_plugin_paths_50.patch 133 + else ./patches/nix_plugin_paths_52.patch) 135 134 ]; 136 135 137 136 postPatch = '' ··· 141 140 -e "/python_arch/s/: *'[^']*'/: '""'/" \ 142 141 build/common.gypi chrome/chrome_tests.gypi 143 142 144 - ${optionalString (versionOlder version "51.0.0.0") '' 145 - sed -i -e '/module_path *=.*libexif.so/ { 146 - s|= [^;]*|= base::FilePath().AppendASCII("${libexif}/lib/libexif.so")| 147 - }' chrome/utility/media_galleries/image_metadata_extractor.cc 148 - ''} 149 - 150 143 sed -i -e '/lib_loader.*Load/s!"\(libudev\.so\)!"${udev}/lib/\1!' \ 151 144 device/udev_linux/udev?_loader.cc 152 145 153 146 sed -i -e '/libpci_loader.*Load/s!"\(libpci\.so\)!"${pciutils}/lib/\1!' \ 154 147 gpu/config/gpu_info_collector_linux.cc 155 - '' + optionalString (!versionOlder version "51.0.0.0") '' 148 + 156 149 sed -i -re 's/([^:])\<(isnan *\()/\1std::\2/g' \ 157 150 chrome/browser/ui/webui/engagement/site_engagement_ui.cc 151 + '' + optionalString (versionAtLeast version "52.0.0.0") '' 152 + sed -i -re 's/([^:])\<(isnan *\()/\1std::\2/g' \ 153 + third_party/pdfium/xfa/fxbarcode/utils.h 158 154 ''; 159 155 160 156 gypFlags = mkGypFlags (gypFlagsUseSystemLibs // { ··· 185 181 google_api_key = "AIzaSyDGi15Zwl11UNe6Y-5XW_upsfyw31qwZPI"; 186 182 google_default_client_id = "404761575300.apps.googleusercontent.com"; 187 183 google_default_client_secret = "9rIFQjfnkykEmqb6FfjJQD1D"; 188 - 189 - } // optionalAttrs (versionOlder version "51.0.0.0") { 190 - use_system_libexif = true; 191 184 } // optionalAttrs proprietaryCodecs { 192 185 # enable support for the H.264 codec 193 186 proprietary_codecs = true;
-14
pkgs/applications/networking/browsers/chromium/patches/build_fixes_46.patch
··· 1 - diff --git a/chrome/test/data/webui_test_resources.grd b/chrome/test/data/webui_test_resources.grd 2 - index 6f8530d..f92a76a 100644 3 - --- a/chrome/test/data/webui_test_resources.grd 4 - +++ b/chrome/test/data/webui_test_resources.grd 5 - @@ -6,9 +6,4 @@ 6 - </output> 7 - <output filename="webui_test_resources.pak" type="data_package" /> 8 - </outputs> 9 - - <release seq="1"> 10 - - <includes> 11 - - <include name="IDR_WEBUI_TEST_I18N_PROCESS_CSS_TEST" file="webui/i18n_process_css_test.html" flattenhtml="true" allowexternalscript="true" type="BINDATA" /> 12 - - </includes> 13 - - </release> 14 - </grit>
+11 -16
pkgs/applications/networking/browsers/chromium/patches/nix_plugin_paths_46.patch pkgs/applications/networking/browsers/chromium/patches/nix_plugin_paths_52.patch
··· 1 1 diff --git a/chrome/common/chrome_paths.cc b/chrome/common/chrome_paths.cc 2 - index 74bf041..5f34198 100644 2 + index f4e119d..d9775bd 100644 3 3 --- a/chrome/common/chrome_paths.cc 4 4 +++ b/chrome/common/chrome_paths.cc 5 - @@ -66,21 +66,14 @@ static base::LazyInstance<base::FilePath> 5 + @@ -68,21 +68,14 @@ static base::LazyInstance<base::FilePath> 6 6 g_invalid_specified_user_data_dir = LAZY_INSTANCE_INITIALIZER; 7 7 8 8 // Gets the path for internal plugins. 9 9 -bool GetInternalPluginsDirectory(base::FilePath* result) { 10 - -#if defined(OS_MACOSX) && !defined(OS_IOS) 10 + -#if defined(OS_MACOSX) 11 11 - // If called from Chrome, get internal plugins from a subdirectory of the 12 12 - // framework. 13 13 - if (base::mac::AmIBundled()) { ··· 31 31 + *result = base::FilePath(value); 32 32 } 33 33 34 - #if defined(OS_WIN) 35 - @@ -253,11 +246,11 @@ bool PathProvider(int key, base::FilePath* result) { 34 + // Gets the path for bundled implementations of components. Note that these 35 + @@ -272,7 +265,7 @@ bool PathProvider(int key, base::FilePath* result) { 36 36 create_dir = true; 37 37 break; 38 38 case chrome::DIR_INTERNAL_PLUGINS: 39 39 - if (!GetInternalPluginsDirectory(&cur)) 40 40 + if (!GetInternalPluginsDirectory(&cur, "ALL")) 41 + return false; 42 + break; 43 + case chrome::DIR_COMPONENTS: 44 + @@ -280,7 +273,7 @@ bool PathProvider(int key, base::FilePath* result) { 41 45 return false; 42 46 break; 43 47 case chrome::DIR_PEPPER_FLASH_PLUGIN: ··· 46 50 return false; 47 51 cur = cur.Append(kPepperFlashBaseDirectory); 48 52 break; 49 - @@ -314,7 +307,7 @@ bool PathProvider(int key, base::FilePath* result) { 53 + @@ -323,7 +316,7 @@ bool PathProvider(int key, base::FilePath* result) { 50 54 // We currently need a path here to look up whether the plugin is disabled 51 55 // and what its permissions are. 52 56 case chrome::FILE_NACL_PLUGIN: ··· 55 59 return false; 56 60 cur = cur.Append(kInternalNaClPluginFileName); 57 61 break; 58 - @@ -349,7 +342,7 @@ bool PathProvider(int key, base::FilePath* result) { 62 + @@ -358,7 +351,7 @@ bool PathProvider(int key, base::FilePath* result) { 59 63 cur = cur.DirName(); 60 64 } 61 65 #else ··· 64 68 return false; 65 69 #endif 66 70 cur = cur.Append(FILE_PATH_LITERAL("pnacl")); 67 - @@ -366,7 +359,7 @@ bool PathProvider(int key, base::FilePath* result) { 68 - // In the component case, this is the source adapter. Otherwise, it is the 69 - // actual Pepper module that gets loaded. 70 - case chrome::FILE_WIDEVINE_CDM_ADAPTER: 71 - - if (!GetInternalPluginsDirectory(&cur)) 72 - + if (!GetInternalPluginsDirectory(&cur, "WIDEVINE")) 73 - return false; 74 - cur = cur.AppendASCII(kWidevineCdmAdapterFileName); 75 - break;
+9 -9
pkgs/applications/networking/browsers/chromium/upstream-info.nix
··· 1 1 # This file is autogenerated from update.sh in the same directory. 2 2 { 3 3 beta = { 4 - sha256 = "0l1434wqhi6c24qyb5ysg1wnd0s9l9i1k6kh6wr3s4acrsbb7p12"; 5 - sha256bin64 = "1ssw92l8zwj8x0zs5h6vxl7d7gj0lqb0x71vsazgd4d0p23nglb1"; 6 - version = "51.0.2704.47"; 4 + sha256 = "1sgfwh2b0aw6l5v4ggk7frcy306x3ygxk81p3h6zdy5s1rpf8hxj"; 5 + sha256bin64 = "14qj8l5dapha87ndyzcs3spaxp3s9sapcjcplkisbivis09a29cb"; 6 + version = "51.0.2704.63"; 7 7 }; 8 8 dev = { 9 - sha256 = "0czp4p434yqr5rv3w2vypkyis13x8lc4xph8yh84r9big1ga6fqs"; 10 - sha256bin64 = "0hahamx9k14czswqdh8iwh69lsml0acca5kxvp2kw471g3s55n78"; 11 - version = "52.0.2729.3"; 9 + sha256 = "1bbwbn0svgr2pfkza8pdq61bjzlj50axdm5bqqxi51hab51fc9ww"; 10 + sha256bin64 = "1s02q72b84g9p5i7y1hh1c67qjb92934dqqwd7w6j0jz8ix71nzc"; 11 + version = "52.0.2743.10"; 12 12 }; 13 13 stable = { 14 - sha256 = "1ijpbmn38znjjb3h8579x5gsclgjx122lvm0afv17gf2j3w5w4qj"; 15 - sha256bin64 = "17vqvxmy6llg7dpc3pxi0qhwpm9qc9rsq8lgknhwwygvkl8g14sb"; 16 - version = "50.0.2661.102"; 14 + sha256 = "1sgfwh2b0aw6l5v4ggk7frcy306x3ygxk81p3h6zdy5s1rpf8hxj"; 15 + sha256bin64 = "1kjnxxf2ak8v1akzxz46r7a7r6bhxjb2y9fhr1fqvks3m4jc5zqw"; 16 + version = "51.0.2704.63"; 17 17 }; 18 18 }