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 82D8D38888C for ; Sat, 25 Jul 2026 08:56:54 +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=1784969815; cv=none; b=dD+b0vcPPclzHxOjEa0y4cMekRi5trDBrZebsdRdvJJSjdjPskhh1UaSsgnDiZggMYNjteBMNVhNqH1mV9gXiwCs3gJ9z7Is1BHdtL8BBAtrBTunqEuAw8r/u45+wG9jXn2iwXJR0fcxVQB8TnmAefrHqohhDO6KHIeFnh9iEQI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784969815; c=relaxed/simple; bh=8cnopsIanh5BGe/m8kHq3DZLK9XAicAarzjfDVTIR1Y=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=U/h+zxL5YDAwIGqjrwc8DO1qRfsx1N0rxt+AkImLY+F0bu57KK9Wi7Vjz8PoGhZl2NQbX2gWqeRUhwHLSQObAGA4TJVj569A7vPiCKflNu3MJTiiVCkIG7FPz/ZIy1Djbsq6SKejLXovQAMwWp6kppw5uLrzD+as0KRI8mruUHw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=xMcj8mau; 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="xMcj8mau" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8B5AA1F000E9; Sat, 25 Jul 2026 08:56:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1784969814; bh=Ntp9IPYi8buas0XGWxxTNgHnPklz9NYE8T41Mq2vJAM=; h=From:To:Cc:Subject:Date:Reply-To; b=xMcj8mauLHOamsY16NyXwmwhf/tSWul2R65hAUMoPgwqH58bjfecS0YviIwKqWA8i GnajS7yAx4Kg6SPKkRKzej99JeDj8JcConO0Miqp3Dzs5geaSw9argBG/MnpSQUR8H IhV8eryrkc0wmgdu1Gh/APc3AVYH9Oxx/EJ7ERCU= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-64389: ksmbd: validate NTLMv2 response before updating session key Date: Sat, 25 Jul 2026 10:50:06 +0200 Message-ID: <2026072527-CVE-2026-64389-de36@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=3197; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=8Ae9anxX/NaQTkomttNLnejd8xy83oNae3BQAjWrnaA=; b=owGbwMvMwCRo6H6F97bub03G02pJDFkpFdGd+bu5XvAvmXTn8ovZ37N0X/h//as0m6H96F4uD zvfWyLMHbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjCRqh8MC9awbnmwMODRUYf7 97fnvtzGNU/h2AmGBVv0mKYtKz/vc8CtQNZqekie9alHHgA= 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: validate NTLMv2 response before updating session key ksmbd_auth_ntlmv2() derives the NTLMv2 session key into sess->sess_key before it verifies the NTLMv2 response. ksmbd_decode_ntlmssp_auth_blob() then continues into KEY_XCH even when ksmbd_auth_ntlmv2() failed. With SMB3 multichannel binding, the failed authentication operates on an existing session and the session setup error path does not expire binding sessions. A client can send a binding session setup with a bad NT proof and KEY_XCH and still modify sess->sess_key before STATUS_LOGON_FAILURE is returned. Relevant path: smb2_sess_setup() -> conn->binding = true -> ntlm_authenticate() -> session_user() -> ksmbd_decode_ntlmssp_auth_blob() -> ksmbd_auth_ntlmv2() -> calc_ntlmv2_hash() -> hmac_md5_usingrawkey(..., sess->sess_key) -> crypto_memneq() returns mismatch -> KEY_XCH arc4_crypt(..., sess->sess_key, ...) -> out_err without expiring the binding session Derive the base session key into a local buffer and copy it to sess->sess_key only after the proof matches. Return immediately on authentication failure so KEY_XCH is only processed after successful authentication. The Linux kernel CVE team has assigned CVE-2026-64389 to this issue. Affected and fixed versions =========================== Issue introduced in 5.15 with commit e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9 and fixed in 6.18.40 with commit b56400364aed5c34d6e1a0b493081290a5328a9c Issue introduced in 5.15 with commit e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9 and fixed in 7.1.4 with commit 89ca7756d5566ba636bb9092cdbe57dab095e136 Issue introduced in 5.15 with commit e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9 and fixed in 7.2-rc1 with commit 954d196bebb2b50151cb96454c72dc113b2af1ac 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-64389 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/auth.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/b56400364aed5c34d6e1a0b493081290a5328a9c https://git.kernel.org/stable/c/89ca7756d5566ba636bb9092cdbe57dab095e136 https://git.kernel.org/stable/c/954d196bebb2b50151cb96454c72dc113b2af1ac