From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7A96D283FD4 for ; Sat, 25 Jul 2026 08:59:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784969945; cv=none; b=T7pxbFE/AXPN+Q3xwb4MyfgTI0sILcD6GdIPtDRzpQXsgydZ/FfCj2Wxokuj02wpkgMf7rcx4ZyppYHNFRkuR11N7wdN5e0EqHwhvfqByhjPOWJ6luO51/viAoy4Fs2KrT/7RP9GQxRZx6bRdXZvA/8j36XnTS/0ob53s/mX/zM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784969945; c=relaxed/simple; bh=LUegoOkK4vQWzqDqz4inEiHElOvbzI03N8rZtuBOhj0=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=nVPmKRkyw105HiJHCbcSv6YlzgMFdCF+C2Uppjb4v5liwygOGE55ktmc0Oh58hzqEDz3ibNv0N9waMGmH4IV/IsxkkGLepxbJ5QKFkivFZ/wiLJFXurxYAy4OceqLxbynoQfwMQlKuRe61SJT0G7HAFcfDfAabqvR/QxIZuFlO4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=1lUZGKFn; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="1lUZGKFn" Received: by smtp.kernel.org (Postfix) with ESMTPSA id D83631F00A3D; Sat, 25 Jul 2026 08:59:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1784969944; bh=q5aMaKtfZfUg+gAyOxnPF8xMNBWy3NpX7HhGQ/2jOiU=; h=From:To:Cc:Subject:Date:Reply-To; b=1lUZGKFn7oiORGfGo08yJ2dzzDBl4mKQL0WUbhRYQ+VkEAR31rZK92nMI6hDU+bCE cMW0PDh0jskrjAgI+esfSPzi+2qHHioC4m4Lb19gO2XIRLqH/TExfheBduT1l54mKG DFkNqCUgp5skuYBXHYjraSVR0Y3V1vDewzSCUGcU= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-64400: ksmbd: prevent path traversal bypass by restricting caseless retry Date: Sat, 25 Jul 2026 10:50:17 +0200 Message-ID: <2026072529-CVE-2026-64400-d372@gregkh> X-Mailer: git-send-email 2.55.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2553; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=c4JAsKaryH1ovuH0hIqwT9DwkXFZQ6brI0e7cjvZwQY=; b=owGbwMvMwCRo6H6F97bub03G02pJDFkpFbEHFv1rW9OrHlU9KVM3/cXMlJ0nln0yeXNizrrUw 56/b39L6IhlYRBkYpAVU2T5so3n6P6KQ4pehranYeawMoEMYeDiFICJzOhgWDBpqaXP5R89+57n y1++d3Xy7YmzmA4zLFjWu3tT+lav6ikPot6UCDYx8x75nwkA X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: ksmbd: prevent path traversal bypass by restricting caseless retry ksmbd_vfs_path_lookup() enforces LOOKUP_BENEATH to restrict path resolution within the share root. When a crafted path attempts to escape the share boundary using parent-directory components ('..'), vfs_path_parent_lookup() detects this and immediately fails, returning -EXDEV. However, a bug exists in __ksmbd_vfs_kern_path() under caseless mode. The function fails to intercept the -EXDEV error and erroneously falls through to the caseless retry logic, which is intended only for genuinely missing files. During this retry process, the path is reconstructed, leading to an unintended LOOKUP_BENEATH bypass that allows write-capable users to create zero-length files or directories outside the exported share. Fix this by ensuring that the execution only proceeds to the caseless lookup retry when the error is specifically -ENOENT. Any other errors, such as -EXDEV from a path traversal attempt, must be returned immediately. The Linux kernel CVE team has assigned CVE-2026-64400 to this issue. Affected and fixed versions =========================== Fixed in 7.1.4 with commit 8c9a4f1327eb71efbf14842e7b8a6d965077eb67 Fixed in 7.2-rc1 with commit 54bab9ba5a9f156ffa9324fcbe5a356fd0242f95 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2026-64400 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: fs/smb/server/vfs.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/8c9a4f1327eb71efbf14842e7b8a6d965077eb67 https://git.kernel.org/stable/c/54bab9ba5a9f156ffa9324fcbe5a356fd0242f95