From 499c6fa2d06dac32e9ffd72cf2c28f2d1fabc2b2 Mon Sep 17 00:00:00 2001 From: technology208 Date: Fri, 14 Jun 2024 18:44:16 +0800 Subject: [PATCH] CVE-2024-36931 --- 0005-CVE-2024-36931.patch | 25 +++++++++++++++++++++++++ kernel.spec | 7 ++++++- 2 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 0005-CVE-2024-36931.patch diff --git a/0005-CVE-2024-36931.patch b/0005-CVE-2024-36931.patch new file mode 100644 index 00000000..485f0c5f --- /dev/null +++ b/0005-CVE-2024-36931.patch @@ -0,0 +1,25 @@ +From 5ea7475e7e5cb705ab813a4b5ffa4104b7ba6561 Mon Sep 17 00:00:00 2001 +From: technology208 +Date: Fri, 14 Jun 2024 14:05:03 +0800 +Subject: [PATCH] CVE-2024-36931 + +--- + drivers/s390/cio/cio_inject.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/drivers/s390/cio/cio_inject.c b/drivers/s390/cio/cio_inject.c +index 8613fa937..a2e771eba 100644 +--- a/drivers/s390/cio/cio_inject.c ++++ b/drivers/s390/cio/cio_inject.c +@@ -95,7 +95,7 @@ static ssize_t crw_inject_write(struct file *file, const char __user *buf, + return -EINVAL; + } + +- buffer = vmemdup_user(buf, lbuf); ++ buffer = memdup_user_nul(buf, lbuf); + if (IS_ERR(buffer)) + return -ENOMEM; + +-- +2.43.0 + diff --git a/kernel.spec b/kernel.spec index 4adc48c5..e5962222 100644 --- a/kernel.spec +++ b/kernel.spec @@ -25,7 +25,7 @@ %global upstream_sublevel 0 %global devel_release 10 %global maintenance_release .0.0 -%global pkg_release .10 +%global pkg_release .11 %define with_debuginfo 1 # Do not recompute the build-id of vmlinux in find-debuginfo.sh @@ -95,6 +95,7 @@ Source9998: patches.tar.bz2 Patch0002: 0002-cpupower-clang-compile-support.patch Patch0003: 0003-x86_energy_perf_policy-clang-compile-support.patch Patch0004: 0004-turbostat-clang-compile-support.patch +Patch0005: 0005-CVE-2024-36931.patch #BuildRequires: BuildRequires: module-init-tools, patch >= 2.5.4, bash >= 2.03, tar, llvm-devel @@ -332,6 +333,7 @@ Applypatches series.conf %{_builddir}/kernel-%{version}/linux-%{KernelVer} %patch0002 -p1 %patch0003 -p1 %patch0004 -p1 +%patch0005 -p1 %endif find . \( -name "*.orig" -o -name "*~" \) -exec rm -f {} \; >/dev/null @@ -1008,6 +1010,9 @@ fi %endif %changelog +* Fri Jun 14 2024 technology208 - 6.6.0-10.0.0.11 +- fix CVE-2024-36931 + * Wed Apr 1 2024 Hongchen Zhang - 6.6.0-10.0.0.10 - add LoongArch support -- Gitee