Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 BC1D837B011 for ; Fri, 3 Apr 2026 15:26:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775229972; cv=none; b=XglMZc7Rwwb7P9md1lkCASbicDAjghxP4dU6i+GzXOE0+UedonwWzmZdA86U7IZm/Ln3bUKohGPPsKLV8DUQrCIJdTRYi08yIIa+3jRMmyzfN7ftE0VKZkvZfgha2tW1eHB1RMk06JpHoORrdwu8pbXhXJit8OfZv7twSppi128= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775229972; c=relaxed/simple; bh=4lqlcD9pHSmPZi0SVGpCT1mUT6gcyzo+5gkumZv5RJY=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=qNmkFqjSjYUvlNTzfB0dXVIBzyUD/RNOt+4tYz9pmUhJ2MlgeyVPMqn958q1/OV4WQ3JCw7jKfzJejbZiJIxdh0qXa0etd11gpzE1a3nkIn4fgWoQg2/R1bhUcNOxQc5NPdGEMb1suaSEfhpWtiW/VRYDcI83SkZbuGLSYwb4XA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=loW1ZydJ; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="loW1ZydJ" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 47188C4CEF7; Fri, 3 Apr 2026 15:26:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1775229972; bh=4lqlcD9pHSmPZi0SVGpCT1mUT6gcyzo+5gkumZv5RJY=; h=From:To:Cc:Subject:Date:Reply-To:From; b=loW1ZydJlce/k7tLZtJJ5x0jw8JPiUfHPVqEwnTGnJWLNkz5gc37j4JR8t1Ogl2uk hNd5GmDHAOrXChJfZKxhzVKKL13u3L89Av3RndV1/r8l9g3NTuCfjnGmhTV4+Q9dSW Bz1S/8Wamk64ZV603waq32pdA2X05HmJCXjgUEkc= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-23440: net/mlx5e: Fix race condition during IPSec ESN update Date: Fri, 3 Apr 2026 17:18:21 +0200 Message-ID: <2026040313-CVE-2026-23440-9b9f@gregkh> X-Mailer: git-send-email 2.53.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=3907; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=mg2/wSntGxE4GPF6vZltpP7rqq3LCUSvh1nHrS9Oy4Y=; b=owGbwMvMwCRo6H6F97bub03G02pJDJnnb5kyM3R+zmDaXCe8sayik3vPnSp7phqF60x3py0zn XFgQe+3jlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZjI9kMMC6ZXljHz2nydYTBB KqfenunnIt4HDAzzKwOVZOoWrFmy0lFWWKB49gGj2o5OAA== 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: net/mlx5e: Fix race condition during IPSec ESN update In IPSec full offload mode, the device reports an ESN (Extended Sequence Number) wrap event to the driver. The driver validates this event by querying the IPSec ASO and checking that the esn_event_arm field is 0x0, which indicates an event has occurred. After handling the event, the driver must re-arm the context by setting esn_event_arm back to 0x1. A race condition exists in this handling path. After validating the event, the driver calls mlx5_accel_esp_modify_xfrm() to update the kernel's xfrm state. This function temporarily releases and re-acquires the xfrm state lock. So, need to acknowledge the event first by setting esn_event_arm to 0x1. This prevents the driver from reprocessing the same ESN update if the hardware sends events for other reason. Since the next ESN update only occurs after nearly 2^31 packets are received, there's no risk of missing an update, as it will happen long after this handling has finished. Processing the event twice causes the ESN high-order bits (esn_msb) to be incremented incorrectly. The driver then programs the hardware with this invalid ESN state, which leads to anti-replay failures and a complete halt of IPSec traffic. Fix this by re-arming the ESN event immediately after it is validated, before calling mlx5_accel_esp_modify_xfrm(). This ensures that any spurious, duplicate events are correctly ignored, closing the race window. The Linux kernel CVE team has assigned CVE-2026-23440 to this issue. Affected and fixed versions =========================== Issue introduced in 6.4 with commit fef06678931ff67b158d337b581e5cf5ca40a3a3 and fixed in 6.6.130 with commit 3dffc083292e6872787bd7e34b957627622f9af4 Issue introduced in 6.4 with commit fef06678931ff67b158d337b581e5cf5ca40a3a3 and fixed in 6.12.78 with commit 2051c709dce92da3550040aa7949cd5a9c89b14e Issue introduced in 6.4 with commit fef06678931ff67b158d337b581e5cf5ca40a3a3 and fixed in 6.18.20 with commit 96c9c25b74686ac2de15921c9ad30c5ef13af8cd Issue introduced in 6.4 with commit fef06678931ff67b158d337b581e5cf5ca40a3a3 and fixed in 6.19.10 with commit 8d625c15471fb8780125eaef682983a96af77bdc Issue introduced in 6.4 with commit fef06678931ff67b158d337b581e5cf5ca40a3a3 and fixed in 7.0-rc5 with commit beb6e2e5976a128b0cccf10d158124422210c5ef 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-23440 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: drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec_offload.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/3dffc083292e6872787bd7e34b957627622f9af4 https://git.kernel.org/stable/c/2051c709dce92da3550040aa7949cd5a9c89b14e https://git.kernel.org/stable/c/96c9c25b74686ac2de15921c9ad30c5ef13af8cd https://git.kernel.org/stable/c/8d625c15471fb8780125eaef682983a96af77bdc https://git.kernel.org/stable/c/beb6e2e5976a128b0cccf10d158124422210c5ef