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 A75C11F4709 for ; Mon, 21 Oct 2024 12:16:36 +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=1729512996; cv=none; b=PrxmPw9wkMMdljXKSKzt5Q6EA+zg4A8O1LqGRRqraBTX98JN6BI1CjD3ezaAd244oD9P/tUnlcnTIvqy2FAKsSH09jws+2SLi/z5rQPO54kBFY8t5boghHphGLQlnNMhbWV087/XU0smG5Axp7stFmKqZ+0xTwp+B8Tiu9OFAfw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729512996; c=relaxed/simple; bh=QAestvT+cyZb0KmcoYanN8ghNISvdI3tUZV81AwHjb8=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=ITYWTQ++VzS96RbFXEZqb21BLtYUpMTKu4E+o5Je9AMcI6BiuVHPviep0+uOBaSqb1fn0xCbd6VSIKdzsfW/QM0MVbzA8jtdy5Ck4823ys2Pv0Zmx4vVz47OARJft5LqTQ0cOycYas2XWB3WSo3vOM826/tpeNTCI6rMXICH6Qc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=WHSs8DHA; 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="WHSs8DHA" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 24473C4CEC3; Mon, 21 Oct 2024 12:16:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1729512996; bh=QAestvT+cyZb0KmcoYanN8ghNISvdI3tUZV81AwHjb8=; h=From:To:Cc:Subject:Date:Reply-to:From; b=WHSs8DHAqaEH2f9XPcvcmU6TWokbKjfy25RfjqEMClrJBURUNdYpr+hPiAAFxVilC rfC+k8Dtr7PE2NvnHpTNWjNe5WS4d1D7YGn4yx+rp7rN6/ze3aNa5cAexf3Lc3vHQl jhsEZRSb+LH4Q6fBkbiDebawtC783DFdY5sb/mTY= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2024-47727: x86/tdx: Fix "in-kernel MMIO" check Date: Mon, 21 Oct 2024 14:16:06 +0200 Message-ID: <2024102105-CVE-2024-47727-1049@gregkh> X-Mailer: git-send-email 2.47.0 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=2679; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=QAestvT+cyZb0KmcoYanN8ghNISvdI3tUZV81AwHjb8=; b=owGbwMvMwCRo6H6F97bub03G02pJDOlibqwTf1m3n49JKhJ/pdk868aFxTON6t8yrF9ZffPQP oVVW/rfdsSyMAgyMciKKbJ82cZzdH/FIUUvQ9vTMHNYmUCGMHBxCsBELjszLGhbdH3B2v1Mxtb2 i3yCj3Pz6v6/+YZhvmvpjOV8D2r9OKq5+s+u5Y+cH266DQA= 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: x86/tdx: Fix "in-kernel MMIO" check TDX only supports kernel-initiated MMIO operations. The handle_mmio() function checks if the #VE exception occurred in the kernel and rejects the operation if it did not. However, userspace can deceive the kernel into performing MMIO on its behalf. For example, if userspace can point a syscall to an MMIO address, syscall does get_user() or put_user() on it, triggering MMIO #VE. The kernel will treat the #VE as in-kernel MMIO. Ensure that the target MMIO address is within the kernel before decoding instruction. The Linux kernel CVE team has assigned CVE-2024-47727 to this issue. Affected and fixed versions =========================== Issue introduced in 5.19 with commit 31d58c4e557d and fixed in 6.1.113 with commit 25703a3c980e Issue introduced in 5.19 with commit 31d58c4e557d and fixed in 6.6.54 with commit 4c0c5dcb5471 Issue introduced in 5.19 with commit 31d58c4e557d and fixed in 6.10.13 with commit 18ecd5b74682 Issue introduced in 5.19 with commit 31d58c4e557d and fixed in 6.11.2 with commit bca2e29f7e26 Issue introduced in 5.19 with commit 31d58c4e557d and fixed in 6.12-rc1 with commit d4fc4d014715 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-2024-47727 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: arch/x86/coco/tdx/tdx.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/25703a3c980e21548774eea8c8a87a75c5c8f58c https://git.kernel.org/stable/c/4c0c5dcb5471de5fc8f0a1c4980e5815339e1cee https://git.kernel.org/stable/c/18ecd5b74682839e7cdafb7cd1ec106df7baa18c https://git.kernel.org/stable/c/bca2e29f7e26ce7c3522f8b324c0bd85612f68e3 https://git.kernel.org/stable/c/d4fc4d01471528da8a9797a065982e05090e1d81