{"id":"CVE-2023-52874","summary":"x86/tdx: Zero out the missing RSI in TDX_HYPERCALL macro","details":"In the Linux kernel, the following vulnerability has been resolved:\n\nx86/tdx: Zero out the missing RSI in TDX_HYPERCALL macro\n\nIn the TDX_HYPERCALL asm, after the TDCALL instruction returns from the\nuntrusted VMM, the registers that the TDX guest shares to the VMM need\nto be cleared to avoid speculative execution of VMM-provided values.\n\nRSI is specified in the bitmap of those registers, but it is missing\nwhen zeroing out those registers in the current TDX_HYPERCALL.\n\nIt was there when it was originally added in commit 752d13305c78\n(\"x86/tdx: Expand __tdx_hypercall() to handle more arguments\"), but was\nlater removed in commit 1e70c680375a (\"x86/tdx: Do not corrupt\nframe-pointer in __tdx_hypercall()\"), which was correct because %rsi is\nlater restored in the \"pop %rsi\".  However a later commit 7a3a401874be\n(\"x86/tdx: Drop flags from __tdx_hypercall()\") removed that \"pop %rsi\"\nbut forgot to add the \"xor %rsi, %rsi\" back.\n\nFix by adding it back.","modified":"2026-04-02T09:43:26.356308Z","published":"2024-05-21T15:32:07.937Z","related":["SUSE-SU-2024:2571-1","SUSE-SU-2024:2896-1","SUSE-SU-2024:2973-1","SUSE-SU-2025:20008-1","SUSE-SU-2025:20028-1","SUSE-SU-2026:0474-1","SUSE-SU-2026:0496-1"],"database_specific":{"cna_assigner":"Linux","osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2023/52xxx/CVE-2023-52874.json"},"references":[{"type":"WEB","url":"https://git.kernel.org/stable/c/2191950d35d8f81620ea8d4e04d983f664fe3a8a"},{"type":"WEB","url":"https://git.kernel.org/stable/c/5d092b66119d774853cc9308522620299048a662"},{"type":"WEB","url":"https://git.kernel.org/stable/c/de4c5bacca4f50233f1f791bec9eeb4dee1b14cd"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2023/52xxx/CVE-2023-52874.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2023-52874"},{"type":"PACKAGE","url":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"7a3a401874bea02f568aa416ac29170d8cde0dc2"},{"fixed":"2191950d35d8f81620ea8d4e04d983f664fe3a8a"},{"fixed":"de4c5bacca4f50233f1f791bec9eeb4dee1b14cd"},{"fixed":"5d092b66119d774853cc9308522620299048a662"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2023-52874.json"}}],"schema_version":"1.7.5"}