ksmbd: Update to version 3.5.0

Changelogs:
https://github.com/cifsd-team/ksmbd/releases/tag/3.4.9
https://github.com/cifsd-team/ksmbd/releases/tag/3.5.0

This fixes some security problems.

Link: https://github.com/openwrt/openwrt/pull/15871
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
This commit is contained in:
Hauke Mehrtens 2024-07-04 22:59:49 +02:00
parent 466198c9eb
commit d5ba3ca35c
2 changed files with 9 additions and 3 deletions

View File

@ -1,12 +1,12 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=ksmbd PKG_NAME:=ksmbd
PKG_VERSION:=3.4.8 PKG_VERSION:=3.5.0
PKG_RELEASE:=1 PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://github.com/cifsd-team/ksmbd/releases/download/$(PKG_VERSION) PKG_SOURCE_URL:=https://github.com/cifsd-team/ksmbd/releases/download/$(PKG_VERSION)
PKG_HASH:=209bfba4dc5c50007942a3ec24f86a7f7c628618ac07f79c62e3404dc247d495 PKG_HASH:=ceb11850bee8ff3575228e1b691d83d710cd9cb586bdaf8e5769d06b82eaaf05
PKG_LICENSE:=GPL-2.0-or-later PKG_LICENSE:=GPL-2.0-or-later
PKG_LICENSE_FILES:=COPYING PKG_LICENSE_FILES:=COPYING

View File

@ -3,7 +3,7 @@ https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=linux
--- a/vfs.c --- a/vfs.c
+++ b/vfs.c +++ b/vfs.c
@@ -1081,12 +1081,18 @@ static int __ksmbd_vfs_rename(struct ksm @@ -1582,7 +1582,9 @@ static int __ksmbd_vfs_rename(struct ksm
err = -ENOTEMPTY; err = -ENOTEMPTY;
if (dst_dent != trap_dent && !d_really_is_positive(dst_dent)) { if (dst_dent != trap_dent && !d_really_is_positive(dst_dent)) {
@ -11,6 +11,12 @@ https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=linux
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 12, 0) || \ +#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 12, 0) || \
+ (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 220) && \ + (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 220) && \
+ LINUX_VERSION_CODE < KERNEL_VERSION(5, 11, 0)) + LINUX_VERSION_CODE < KERNEL_VERSION(5, 11, 0))
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 3, 0)
struct renamedata rd = {
.old_mnt_idmap = src_idmap,
@@ -1594,10 +1596,14 @@ static int __ksmbd_vfs_rename(struct ksm
};
#else
struct renamedata rd = { struct renamedata rd = {
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 12, 0) +#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 12, 0)
.old_mnt_userns = src_user_ns, .old_mnt_userns = src_user_ns,