CVE-2023-52598: s390/ptrace: handle setting of fpc register correctly
In the Linux kernel, the following vulnerability has been resolved:
s390/ptrace: handle setting of fpc register correctly
If the content of the floating point control (fpc) register of a traced process is modified with the ptrace interface the new value is tested for validity by temporarily loading it into the fpc register.
This may lead to corruption of the fpc register of the tracing process: if an interrupt happens while the value is temporarily loaded into the fpc register, and within interrupt context floating point or vector registers are used, the current fp/vx registers are saved with savefpuregs() assuming they belong to user space and will be loaded into fp/vx registers when returning to user space.
testfpctl() restores the original user space fpc register value, however it will be discarded, when returning to user space.
In result the tracer will incorrectly continue to run with the value that was supposed to be used for the traced process.
Fix this by saving fpu register contents with savefpuregs() before using testfpctl().
Other sources
In the Linux kernel, the following vulnerability has been resolved:
s390/ptrace: handle setting of fpc register correctly
The Linux kernel CVE team has assigned CVE-2023-52598 to this issue.
Upstream advisory: https://lore.kernel.org/linux-cve-announce/2024030646-CVE-2023-52598-d0a2@gregkh/T
— Red Hat
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
debian/linuxto a version that resolves this vulnerability.Fixed in 5.10.223-1Fixed in 5.10.234-1Fixed in 6.1.129-1Fixed in 6.1.135-1Fixed in 6.12.25-1Fixed in 6.12.27-1 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 4.19.307 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 5.4.269 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 5.10.210 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 5.15.149 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 6.1.77 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 6.6.16 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 6.7.4 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 6.8 - Compensating control
In s390/ptrace handling, save FPU register contents with save_fpu_regs() before using test_fp_ctl().
Event History
Frequently Asked Questions
What is the severity of CVE-2023-52598?
The severity of CVE-2023-52598 is classified as high due to potential manipulation of the floating point control (fpc) register.
How do I fix CVE-2023-52598?
To fix CVE-2023-52598, update to the fixed versions of the kernel: 4.19.307, 5.4.269, 5.10.210, 5.15.149, 6.1.77, 6.6.16, 6.7.4, 6.8 for Red Hat or specific versions for Debian such as 5.10.223-1.
Which Linux kernel versions are affected by CVE-2023-52598?
CVE-2023-52598 affects various Linux kernel versions prior to their respective patched versions including 4.19.307, 5.4.269, and 5.10.210.
What is the impact of CVE-2023-52598 on systems?
CVE-2023-52598 could lead to unauthorized modifications of the floating point control register, potentially affecting the behavior of traced processes.
Is there any workaround for CVE-2023-52598 before patching?
Currently, there are no known workarounds for preventing CVE-2023-52598 without applying the necessary patches.