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 86C3B101F2 for ; Tue, 16 Jul 2024 11:46:08 +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=1721130368; cv=none; b=c0Ew6304Oagb1sjBy0BrLWI9vncXnwqPuD3UMdHz2ZzoFV4hQ7sOcQha9o9AM61cCMnrBkyV+dMv3fmotFnuHFyb71R34yZiOQO7Y9KAXZvI6Bi4DayY0Yv9QtXBpl7hkLkeQhuug46AOffpAEz89p1BHVhGpKucg9mojzx/iiE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1721130368; c=relaxed/simple; bh=1XUhBK7UOLmyvY2svszxflrqACkCCb2oQ9/y+f7QkUg=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=McLPJNAReLtB+ju/eQ3+imzRQXOUZjgziPXo7CDBJY7Sy5QZOChYzv51Hm1yDbBOVGVCor4+Dq3NwpYrA42jnFK9my2njmyKfhdQrXABxpN/e3wfCxdMqA6deQo7pFNdruwDm+oQVZG/8CMfYeSSvQpX0N9O5pYX/+4xqf23Uiw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=NiZl07nV; 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="NiZl07nV" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 06089C116B1; Tue, 16 Jul 2024 11:46:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1721130368; bh=1XUhBK7UOLmyvY2svszxflrqACkCCb2oQ9/y+f7QkUg=; h=From:To:Cc:Subject:Date:Reply-to:From; b=NiZl07nVhuaHAvVfUBO7CnWb/+7K1Qw7Yy7VyH5AryMc/qr2pBuraSAOoFQEgctDY od6kjklHpNrb75nR1JeECpibL7ItOaaRXP0MW+P11FbLBG8leglWl0Bu8yFCVwmf/v HD1T6mI6KA+rl4d5iG6WmpxHdJMLpySk05QBtzRw= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-48789: nvme-tcp: fix possible use-after-free in transport error_recovery work Date: Tue, 16 Jul 2024 13:45:41 +0200 Message-ID: <2024071640-CVE-2022-48789-a066@gregkh> X-Mailer: git-send-email 2.45.2 Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Reply-to: , X-Developer-Signature: v=1; a=openpgp-sha256; l=2369; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=1XUhBK7UOLmyvY2svszxflrqACkCCb2oQ9/y+f7QkUg=; b=owGbwMvMwCRo6H6F97bub03G02pJDGnTYlNU9BZp2kx+NWuJN5ux1Vxh7RML+1+pSnyX0fBwu F6t37qzI5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACbCfZ9hQcM3xe+uE+danVbZ drKv+OeX5LUfhRgW3FjXF/T6d7PBo+N/PZtL9p5/xcbfDwA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit Description =========== In the Linux kernel, the following vulnerability has been resolved: nvme-tcp: fix possible use-after-free in transport error_recovery work While nvme_tcp_submit_async_event_work is checking the ctrl and queue state before preparing the AER command and scheduling io_work, in order to fully prevent a race where this check is not reliable the error recovery work must flush async_event_work before continuing to destroy the admin queue after setting the ctrl state to RESETTING such that there is no race .submit_async_event and the error recovery handler itself changing the ctrl state. The Linux kernel CVE team has assigned CVE-2022-48789 to this issue. Affected and fixed versions =========================== Fixed in 5.4.181 with commit 61a26ffd5ad3 Fixed in 5.10.102 with commit e192184cf8bc Fixed in 5.15.25 with commit 5e42fca37ccc Fixed in 5.16.11 with commit bb0d8fb35c4f Fixed in 5.17 with commit ff9fc7ebf5c0 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-2022-48789 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/nvme/host/tcp.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/61a26ffd5ad3ece456d74c4c79f7b5e3f440a141 https://git.kernel.org/stable/c/e192184cf8bce8dd55d619f5611a2eaba996fa05 https://git.kernel.org/stable/c/5e42fca37ccc76f39f73732661bd47254cad5982 https://git.kernel.org/stable/c/bb0d8fb35c4ff00a503c2c4dca4cce8d102a21c4 https://git.kernel.org/stable/c/ff9fc7ebf5c06de1ef72a69f9b1ab40af8b07f9e