diff --git a/extra/chromium/PKGBUILD b/extra/chromium/PKGBUILD index 4fa8bc4e3..a2db18358 100644 --- a/extra/chromium/PKGBUILD +++ b/extra/chromium/PKGBUILD @@ -16,7 +16,7 @@ highmem=1 pkgname=chromium pkgver=81.0.4044.138 -pkgrel=2 +pkgrel=2.1 _launcher_ver=6 pkgdesc="A web browser built for speed, simplicity, and security" arch=('x86_64') @@ -40,7 +40,8 @@ source=(https://commondatastorage.googleapis.com/chromium-browser-official/$pkgn icu67.patch chromium-widevine.patch chromium-skia-harmony.patch - 0001-crashpad-include-limits.patch) + 0001-crashpad-include-limits.patch + chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407.patch) sha256sums=('f478f28b8111cb70231df4c36e754d812ad7a94b7c844e9d0515345a71fd77a6' '04917e3cd4307d8e31bfb0027a5dce6d086edb10ff8a716024fbb8bb0c7dccf1' 'ae3bf107834bd8eda9a3ec7899fe35fde62e6111062e5def7d24bf49b53db3db' @@ -49,7 +50,8 @@ sha256sums=('f478f28b8111cb70231df4c36e754d812ad7a94b7c844e9d0515345a71fd77a6' '5315977307e69d20b3e856d3f8724835b08e02085a4444a5c5cefea83fd7d006' '709e2fddba3c1f2ed4deb3a239fc0479bfa50c46e054e7f32db4fb1365fed070' '771292942c0901092a402cc60ee883877a99fb804cb54d568c8c6c94565a48e1' - 'df99f49ad58b70c9a3e1827d7e80b62e4363419334ed83373cf55b79c17b6f10') + 'df99f49ad58b70c9a3e1827d7e80b62e4363419334ed83373cf55b79c17b6f10' + '4837f797a910795bf3161805a3302d5f3701573ca90da8af32b2f4aa62510d20') # Possible replacements are listed in build/linux/unbundle/replace_gn_files.py # Keys are the names in the above script; values are the dependencies in Arch @@ -95,6 +97,7 @@ prepare() { # Arch Linux ARM fixes patch -p1 -i ../0001-crashpad-include-limits.patch + patch -p1 -i ../chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407.patch # Build ARMv7 with NEON [[ $CARCH == "armv7h" ]] && MAKEFLAGS="-j4" && CFLAGS=`echo $CFLAGS | sed -e 's/vfpv3-d16/neon/'` && CXXFLAGS="$CFLAGS" diff --git a/extra/chromium/chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407.patch b/extra/chromium/chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407.patch new file mode 100644 index 000000000..7766ad354 --- /dev/null +++ b/extra/chromium/chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407.patch @@ -0,0 +1,85 @@ +diff -rauN chromium-81.0.4044.122/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407-patch/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc +--- chromium-81.0.4044.122/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc 2020-04-21 23:50:38.000000000 +0200 ++++ chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407-patch/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc 2020-04-24 08:23:49.283333424 +0200 +@@ -148,7 +148,14 @@ + return Allow(); + #endif + +- if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep) { ++ if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep ++#if defined(__NR_clock_gettime64) ++ || sysno == __NR_clock_gettime64 ++#endif ++#if defined(__NR_clock_nanosleep_time64) ++ || sysno == __NR_clock_nanosleep_time64 ++#endif ++ ) { + return RestrictClockID(); + } + +diff -rauN chromium-81.0.4044.122/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407-patch/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc +--- chromium-81.0.4044.122/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc 2020-04-21 23:50:02.000000000 +0200 ++++ chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407-patch/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc 2020-04-24 08:29:04.760000078 +0200 +@@ -60,6 +60,12 @@ + case __NR_clock_gettime: + case __NR_clock_getres: + case __NR_clock_nanosleep: ++#if defined(__NR_clock_nanosleep_time64) ++ case __NR_clock_nanosleep_time64: ++#endif ++#if defined(__NR_clock_gettime64) ++ case __NR_clock_gettime64: ++#endif + return RestrictClockID(); + default: + return Allow(); +diff -rauN chromium-81.0.4044.122/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407-patch/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc +--- chromium-81.0.4044.122/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc 2020-04-21 23:50:02.000000000 +0200 ++++ chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407-patch/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc 2020-04-24 08:32:50.016666736 +0200 +@@ -39,6 +39,12 @@ + // filtered by RestrictClokID(). + case __NR_clock_gettime: // Parameters filtered by RestrictClockID(). + case __NR_clock_nanosleep: // Parameters filtered by RestrictClockID(). ++#if defined(__NR_clock_gettime64) ++ case __NR_clock_gettime64: // Parameters filtered by RestrictClockID(). ++#endif ++#if defined(__NR_clock_nanosleep_time64) ++ case __NR_clock_nanosleep_time64: // Parameters filtered by RestrictClockID(). ++#endif + case __NR_clock_settime: // Privileged. + #if defined(__i386__) || \ + (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) +diff -rauN chromium-81.0.4044.122/sandbox/linux/system_headers/arm_linux_syscalls.h chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407-patch/sandbox/linux/system_headers/arm_linux_syscalls.h +--- chromium-81.0.4044.122/sandbox/linux/system_headers/arm_linux_syscalls.h 2020-04-21 23:50:02.000000000 +0200 ++++ chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407-patch/sandbox/linux/system_headers/arm_linux_syscalls.h 2020-04-24 08:35:06.950000054 +0200 +@@ -1385,6 +1385,14 @@ + #define __NR_memfd_create (__NR_SYSCALL_BASE+385) + #endif + ++#if !defined(__NR_clock_gettime64) ++#define __NR_clock_gettime64 (__NR_SYSCALL_BASE+403) ++#endif ++ ++#if !defined(__NR_clock_nanosleep_time64) ++#define __NR_clock_nanosleep_time64 (__NR_SYSCALL_BASE+407) ++#endif ++ + // ARM private syscalls. + #if !defined(__ARM_NR_BASE) + #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000) +diff -rauN chromium-81.0.4044.122/sandbox/linux/system_headers/mips_linux_syscalls.h chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407-patch/sandbox/linux/system_headers/mips_linux_syscalls.h +--- chromium-81.0.4044.122/sandbox/linux/system_headers/mips_linux_syscalls.h 2020-04-21 23:50:02.000000000 +0200 ++++ chromium-81.0.4044.122-Fix-sandbox-Aw-snap-for-syscalls-403-and-407-patch/sandbox/linux/system_headers/mips_linux_syscalls.h 2020-04-24 08:35:52.130000064 +0200 +@@ -1433,4 +1433,12 @@ + #define __NR_memfd_create (__NR_Linux + 354) + #endif + ++#if !defined(__NR_clock_gettime64) ++#define __NR_clock_gettime64 (__NR_Linux + 403) ++#endif ++ ++#if !defined(__NR_clock_nanosleep_time64) ++#define __NR_clock_nanosleep_time64 (__NR_Linux + 407) ++#endif ++ + #endif // SANDBOX_LINUX_SYSTEM_HEADERS_MIPS_LINUX_SYSCALLS_H_