CVE-2023-52499
IBM FSP-2 Linux Kernel Powerpc 47x System Call Return Crash Vuln
Description
In the Linux kernel, the following vulnerability has been resolved: powerpc/47x: Fix 47x syscall return crash Eddie reported that newer kernels were crashing during boot on his 476 FSP2 system: kernel tried to execute user page (b7ee2000) - exploit attempt? (uid: 0) BUG: Unable to handle kernel instruction fetch Faulting instruction address: 0xb7ee2000 Oops: Kernel access of bad area, sig: 11 [#1] BE PAGE_SIZE=4K FSP-2 Modules linked in: CPU: 0 PID: 61 Comm: mount Not tainted 6.1.55-d23900f.ppcnf-fsp2 #1 Hardware name: ibm,fsp2 476fpe 0x7ff520c0 FSP-2 NIP: b7ee2000 LR: 8c008000 CTR: 00000000 REGS: bffebd83 TRAP: 0400 Not tainted (6.1.55-d23900f.ppcnf-fs p2) MSR: 00000030 <IR,DR> CR: 00001000 XER: 20000000 GPR00: c00110ac bffebe63 bffebe7e bffebe88 8c008000 00001000 00000d12 b7ee2000 GPR08: 00000033 00000000 00000000 c139df10 48224824 1016c314 10160000 00000000 GPR16: 10160000 10160000 00000008 00000000 10160000 00000000 10160000 1017f5b0 GPR24: 1017fa50 1017f4f0 1017fa50 1017f740 1017f630 00000000 00000000 1017f4f0 NIP [b7ee2000] 0xb7ee2000 LR [8c008000] 0x8c008000 Call Trace: Instruction dump: XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX ---[ end trace 0000000000000000 ]--- The problem is in ret_from_syscall where the check for icache_44x_need_flush is done. When the flush is needed the code jumps out-of-line to do the flush, and then intends to jump back to continue the syscall return. However the branch back to label 1b doesn't return to the correct location, instead branching back just prior to the return to userspace, causing bogus register values to be used by the rfi. The breakage was introduced by commit 6f76a01173cc ("powerpc/syscall: implement system call entry/exit logic in C for PPC32") which inadvertently removed the "1" label and reused it elsewhere. Fix it by adding named local labels in the correct locations. Note that the return label needs to be outside the ifdef so that CONFIG_PPC_47x=n compiles.
INFO
Published Date :
March 2, 2024, 10:15 p.m.
Last Modified :
Jan. 13, 2025, 6:29 p.m.
Source :
416baaa9-dc9f-4396-8d5f-8c081fb06d67
Remotely Exploitable :
No
Impact Score :
3.6
Exploitability Score :
1.8
References to Advisories, Solutions, and Tools
Here, you will find a curated list of external links that provide in-depth
information, practical solutions, and valuable tools related to
CVE-2023-52499
.
We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).
Results are limited to the first 15 repositories due to potential performance issues.
The following list is the news that have been mention
CVE-2023-52499
vulnerability anywhere in the article.
The following table lists the changes that have been made to the
CVE-2023-52499
vulnerability over time.
Vulnerability history details can be useful for understanding the evolution of a vulnerability, and for identifying the most recent changes that may impact the vulnerability's severity, exploitability, or other characteristics.
-
Initial Analysis by [email protected]
Jan. 13, 2025
Action Type Old Value New Value Added CVSS V3.1 NIST AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H Added CWE NIST NVD-CWE-noinfo Added CPE Configuration OR *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.12 up to (excluding) 5.15.137 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.16 up to (excluding) 6.1.59 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 6.2 up to (excluding) 6.5.8 *cpe:2.3:o:linux:linux_kernel:6.6:rc1:*:*:*:*:*:* *cpe:2.3:o:linux:linux_kernel:6.6:rc2:*:*:*:*:*:* *cpe:2.3:o:linux:linux_kernel:6.6:rc3:*:*:*:*:*:* *cpe:2.3:o:linux:linux_kernel:6.6:rc4:*:*:*:*:*:* *cpe:2.3:o:linux:linux_kernel:6.6:rc5:*:*:*:*:*:* Changed Reference Type https://git.kernel.org/stable/c/29017ab1a539101d9c7bec63cc13a019f97b2820 No Types Assigned https://git.kernel.org/stable/c/29017ab1a539101d9c7bec63cc13a019f97b2820 Patch Changed Reference Type https://git.kernel.org/stable/c/29017ab1a539101d9c7bec63cc13a019f97b2820 No Types Assigned https://git.kernel.org/stable/c/29017ab1a539101d9c7bec63cc13a019f97b2820 Patch Changed Reference Type https://git.kernel.org/stable/c/70f6756ad96dd70177dddcfac2fe4bd4bb320746 No Types Assigned https://git.kernel.org/stable/c/70f6756ad96dd70177dddcfac2fe4bd4bb320746 Patch Changed Reference Type https://git.kernel.org/stable/c/70f6756ad96dd70177dddcfac2fe4bd4bb320746 No Types Assigned https://git.kernel.org/stable/c/70f6756ad96dd70177dddcfac2fe4bd4bb320746 Patch Changed Reference Type https://git.kernel.org/stable/c/8ac2689502f986a46f4221e239d4ff2897f1ccb3 No Types Assigned https://git.kernel.org/stable/c/8ac2689502f986a46f4221e239d4ff2897f1ccb3 Patch Changed Reference Type https://git.kernel.org/stable/c/8ac2689502f986a46f4221e239d4ff2897f1ccb3 No Types Assigned https://git.kernel.org/stable/c/8ac2689502f986a46f4221e239d4ff2897f1ccb3 Patch Changed Reference Type https://git.kernel.org/stable/c/f0eee815babed70a749d2496a7678be5b45b4c14 No Types Assigned https://git.kernel.org/stable/c/f0eee815babed70a749d2496a7678be5b45b4c14 Patch Changed Reference Type https://git.kernel.org/stable/c/f0eee815babed70a749d2496a7678be5b45b4c14 No Types Assigned https://git.kernel.org/stable/c/f0eee815babed70a749d2496a7678be5b45b4c14 Patch -
CVE Modified by af854a3a-2127-422b-91ae-364da2661108
Nov. 21, 2024
Action Type Old Value New Value Added Reference https://git.kernel.org/stable/c/29017ab1a539101d9c7bec63cc13a019f97b2820 Added Reference https://git.kernel.org/stable/c/70f6756ad96dd70177dddcfac2fe4bd4bb320746 Added Reference https://git.kernel.org/stable/c/8ac2689502f986a46f4221e239d4ff2897f1ccb3 Added Reference https://git.kernel.org/stable/c/f0eee815babed70a749d2496a7678be5b45b4c14 -
CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67
May. 28, 2024
Action Type Old Value New Value -
CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67
May. 14, 2024
Action Type Old Value New Value -
CVE Received by 416baaa9-dc9f-4396-8d5f-8c081fb06d67
Mar. 02, 2024
Action Type Old Value New Value Added Description In the Linux kernel, the following vulnerability has been resolved: powerpc/47x: Fix 47x syscall return crash Eddie reported that newer kernels were crashing during boot on his 476 FSP2 system: kernel tried to execute user page (b7ee2000) - exploit attempt? (uid: 0) BUG: Unable to handle kernel instruction fetch Faulting instruction address: 0xb7ee2000 Oops: Kernel access of bad area, sig: 11 [#1] BE PAGE_SIZE=4K FSP-2 Modules linked in: CPU: 0 PID: 61 Comm: mount Not tainted 6.1.55-d23900f.ppcnf-fsp2 #1 Hardware name: ibm,fsp2 476fpe 0x7ff520c0 FSP-2 NIP: b7ee2000 LR: 8c008000 CTR: 00000000 REGS: bffebd83 TRAP: 0400 Not tainted (6.1.55-d23900f.ppcnf-fs p2) MSR: 00000030 <IR,DR> CR: 00001000 XER: 20000000 GPR00: c00110ac bffebe63 bffebe7e bffebe88 8c008000 00001000 00000d12 b7ee2000 GPR08: 00000033 00000000 00000000 c139df10 48224824 1016c314 10160000 00000000 GPR16: 10160000 10160000 00000008 00000000 10160000 00000000 10160000 1017f5b0 GPR24: 1017fa50 1017f4f0 1017fa50 1017f740 1017f630 00000000 00000000 1017f4f0 NIP [b7ee2000] 0xb7ee2000 LR [8c008000] 0x8c008000 Call Trace: Instruction dump: XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX ---[ end trace 0000000000000000 ]--- The problem is in ret_from_syscall where the check for icache_44x_need_flush is done. When the flush is needed the code jumps out-of-line to do the flush, and then intends to jump back to continue the syscall return. However the branch back to label 1b doesn't return to the correct location, instead branching back just prior to the return to userspace, causing bogus register values to be used by the rfi. The breakage was introduced by commit 6f76a01173cc ("powerpc/syscall: implement system call entry/exit logic in C for PPC32") which inadvertently removed the "1" label and reused it elsewhere. Fix it by adding named local labels in the correct locations. Note that the return label needs to be outside the ifdef so that CONFIG_PPC_47x=n compiles. Added Reference Linux https://git.kernel.org/stable/c/29017ab1a539101d9c7bec63cc13a019f97b2820 [No types assigned] Added Reference Linux https://git.kernel.org/stable/c/8ac2689502f986a46f4221e239d4ff2897f1ccb3 [No types assigned] Added Reference Linux https://git.kernel.org/stable/c/70f6756ad96dd70177dddcfac2fe4bd4bb320746 [No types assigned] Added Reference Linux https://git.kernel.org/stable/c/f0eee815babed70a749d2496a7678be5b45b4c14 [No types assigned]
CWE - Common Weakness Enumeration
While CVE identifies
specific instances of vulnerabilities, CWE categorizes the common flaws or
weaknesses that can lead to vulnerabilities. CVE-2023-52499
is
associated with the following CWEs:
Common Attack Pattern Enumeration and Classification (CAPEC)
Common Attack Pattern Enumeration and Classification
(CAPEC)
stores attack patterns, which are descriptions of the common attributes and
approaches employed by adversaries to exploit the CVE-2023-52499
weaknesses.