CVE-2021-47034
published 2024-02-28CVE-2021-47034: In the Linux kernel, the following vulnerability has been resolved: powerpc/64s: Fix pte update for kernel memory on radix When adding a PTE a ptesync is…
PriorityP415medium4.4CVSS 3.1
AVLACLPRHUINSUCNINAH
EPSS
0.22%
12.7th percentile
In the Linux kernel, the following vulnerability has been resolved:
powerpc/64s: Fix pte update for kernel memory on radix
When adding a PTE a ptesync is needed to order the update of the PTE
with subsequent accesses otherwise a spurious fault may be raised.
radix__set_pte_at() does not do this for performance gains. For
non-kernel memory this is not an issue as any faults of this kind are
corrected by the page fault handler. For kernel memory these faults
are not handled. The current solution is that there is a ptesync in
flush_cache_vmap() which should be called when mapping from the
vmalloc region.
However, map_kernel_page() does not call flush_cache_vmap(). This is
troublesome in particular for code patching with Strict RWX on radix.
In do_patch_instruction() the page frame that contains the instruction
to be patched is mapped and then immediately patched. With no ordering
or synchronization between setting up the PTE and writing to the page
it is possible for faults.
As the code patching is done using __put_user_asm_goto() the resulting
fault is obscured - but using a normal store instead it can be seen:
BUG: Unable to handle kernel data access on write at 0xc008000008f24a3c
Faulting instruction address: 0xc00000000008bd74
Oops: Kernel access of bad area, sig: 11 [#1]
LE PAGE_SIZE=64K MMU=Radix SMP NR_CPUS=2048 NUMA PowerNV
Modules linked in: nop_module(PO+) [last unloaded: nop_module]
CPU: 4 PID: 757 Comm: sh Tainted: P O 5.10.0-rc5-01361-ge3c1b78c8440-dirty #43
NIP: c00000000008bd74 LR: c00000000008bd50 CTR: c000000000025810
REGS: c000000016f634a0 TRAP: 0300 Tainted: P O (5.10.0-rc5-01361-ge3c1b78c8440-dirty)
MSR: 9000000000009033 CR: 44002884 XER: 00000000
CFAR: c00000000007c68c DAR: c008000008f24a3c DSISR: 42000000 IRQMASK: 1
This results in the kind of issue reported here:
https://lore.kernel.org/linuxppc-dev/[email protected]/
Chris Riedl suggested a reliable way to reproduce the issue:
$ mount -t debugfs none /sys/kernel
Affected
17 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| debian | linux | < linux 5.10.38-1 (bookworm) | linux 5.10.38-1 (bookworm) |
| linux | linux | — | — |
| linux | linux | >= f1cb8f9beba8699dd1b4518418191499e53f7b17 < b3d5d0983388d6c4fb35f7d722556d5595f167a7 | b3d5d0983388d6c4fb35f7d722556d5595f167a7 |
| linux | linux | >= f1cb8f9beba8699dd1b4518418191499e53f7b17 < 73f9dccb29e4f82574bec2765c0090cdb0404301 | 73f9dccb29e4f82574bec2765c0090cdb0404301 |
| linux | linux | >= f1cb8f9beba8699dd1b4518418191499e53f7b17 < 84c0762633f2a7ac8399e6b97d3b9bb8e6e1d50f | 84c0762633f2a7ac8399e6b97d3b9bb8e6e1d50f |
| linux | linux | >= f1cb8f9beba8699dd1b4518418191499e53f7b17 < 01ac203e2119d8922126886ddea309fb676f955f | 01ac203e2119d8922126886ddea309fb676f955f |
| linux | linux | >= f1cb8f9beba8699dd1b4518418191499e53f7b17 < e40c52ee67b155ad59f59e73ea136d02685f0e0d | e40c52ee67b155ad59f59e73ea136d02685f0e0d |
| linux | linux | >= f1cb8f9beba8699dd1b4518418191499e53f7b17 < b8b2f37cf632434456182e9002d63cbc4cccc50c | b8b2f37cf632434456182e9002d63cbc4cccc50c |
| linux | linux_kernel | >= 0 < 5.10.38-1 | 5.10.38-1 |
| linux | linux_kernel | >= 0 < 5.10.38-1 | 5.10.38-1 |
| linux | linux_kernel | >= 0 < 5.10.38-1 | 5.10.38-1 |
| linux | linux_kernel | >= 0 < 5.10.38-1 | 5.10.38-1 |
| linux | linux_kernel | >= 4.18 < 4.19.191 | 4.19.191 |
| linux | linux_kernel | >= 4.20 < 5.4.119 | 5.4.119 |
| linux | linux_kernel | >= 5.11 < 5.11.21 | 5.11.21 |
| linux | linux_kernel | >= 5.12 < 5.12.4 | 5.12.4 |
| linux | linux_kernel | >= 5.5 < 5.10.37 | 5.10.37 |
CVSS provenance
nvdv3.14.4MEDIUMCVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:N/I:N/A:H
osv4.4MEDIUM
vendor_debian4.4MEDIUM
vendor_redhat4.4MEDIUM
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
Red Hat
kernel: powerpc/64s: Fix pte update for kernel memory on radix
vendor_redhat·2024-02-28·CVSS 4.4
CVE-2021-47034 [MEDIUM] CWE-400 kernel: powerpc/64s: Fix pte update for kernel memory on radix
kernel: powerpc/64s: Fix pte update for kernel memory on radix
In the Linux kernel, the following vulnerability has been resolved:
powerpc/64s: Fix pte update for kernel memory on radix
When adding a PTE a ptesync is needed to order the update of the PTE
with subsequent accesses otherwise a spurious fault may be raised.
radix__set_pte_at() does not do this for performance gains. For
non-kernel memory this is not an issue as any faults of this kind are
corrected by the page fault handler. For kernel memory these faults
are not handled. The current solution is that there is a ptesync in
flush_cache_vmap() which should be called when mapping from the
vmalloc region.
However, map_kernel_page() does not call flush_cache_vmap(). This is
troublesome in particular for code patching with Strict RW
Debian
CVE-2021-47034: linux - In the Linux kernel, the following vulnerability has been resolved: powerpc/64s...
vendor_debian·2021·CVSS 4.4
CVE-2021-47034 [MEDIUM] CVE-2021-47034: linux - In the Linux kernel, the following vulnerability has been resolved: powerpc/64s...
In the Linux kernel, the following vulnerability has been resolved: powerpc/64s: Fix pte update for kernel memory on radix When adding a PTE a ptesync is needed to order the update of the PTE with subsequent accesses otherwise a spurious fault may be raised. radix__set_pte_at() does not do this for performance gains. For non-kernel memory this is not an issue as any faults of this kind are corrected by the page fault handler. For kernel memory these faults are not handled. The current solution is that there is a ptesync in flush_cache_vmap() which should be called when mapping from the vmalloc region. However, map_kernel_page() does not call flush_cache_vmap(). This is troublesome in particular for code patching with Strict RWX on radix. In do_patch_instruction() the page frame that contai
OSV
CVE-2021-47034: In the Linux kernel, the following vulnerability has been resolved: powerpc/64s: Fix pte update for kernel memory on radix When adding a PTE a ptesync
osv·2024-02-28·CVSS 4.4
CVE-2021-47034 [MEDIUM] CVE-2021-47034: In the Linux kernel, the following vulnerability has been resolved: powerpc/64s: Fix pte update for kernel memory on radix When adding a PTE a ptesync
In the Linux kernel, the following vulnerability has been resolved: powerpc/64s: Fix pte update for kernel memory on radix When adding a PTE a ptesync is needed to order the update of the PTE with subsequent accesses otherwise a spurious fault may be raised. radix__set_pte_at() does not do this for performance gains. For non-kernel memory this is not an issue as any faults of this kind are corrected by the page fault handler. For kernel memory these faults are not handled. The current solution is that there is a ptesync in flush_cache_vmap() which should be called when mapping from the vmalloc region. However, map_kernel_page() does not call flush_cache_vmap(). This is troublesome in particular for code patching with Strict RWX on radix. In do_patch_instruction() the page frame that contai
GHSA
GHSA-xfgg-h5qg-vvvx: In the Linux kernel, the following vulnerability has been resolved:
powerpc/64s: Fix pte update for kernel memory on radix
When adding a PTE a ptesy
ghsa_unreviewed·2024-02-28
CVE-2021-47034 [MEDIUM] GHSA-xfgg-h5qg-vvvx: In the Linux kernel, the following vulnerability has been resolved:
powerpc/64s: Fix pte update for kernel memory on radix
When adding a PTE a ptesy
In the Linux kernel, the following vulnerability has been resolved:
powerpc/64s: Fix pte update for kernel memory on radix
When adding a PTE a ptesync is needed to order the update of the PTE
with subsequent accesses otherwise a spurious fault may be raised.
radix__set_pte_at() does not do this for performance gains. For
non-kernel memory this is not an issue as any faults of this kind are
corrected by the page fault handler. For kernel memory these faults
are not handled. The current solution is that there is a ptesync in
flush_cache_vmap() which should be called when mapping from the
vmalloc region.
However, map_kernel_page() does not call flush_cache_vmap(). This is
troublesome in particular for code patching with Strict RWX on radix.
In do_patch_instruction() the page frame that co
No detection rules found.
No public exploits indexed.
https://git.kernel.org/stable/c/01ac203e2119d8922126886ddea309fb676f955fhttps://git.kernel.org/stable/c/73f9dccb29e4f82574bec2765c0090cdb0404301https://git.kernel.org/stable/c/84c0762633f2a7ac8399e6b97d3b9bb8e6e1d50fhttps://git.kernel.org/stable/c/b3d5d0983388d6c4fb35f7d722556d5595f167a7https://git.kernel.org/stable/c/b8b2f37cf632434456182e9002d63cbc4cccc50chttps://git.kernel.org/stable/c/e40c52ee67b155ad59f59e73ea136d02685f0e0dhttps://git.kernel.org/stable/c/01ac203e2119d8922126886ddea309fb676f955fhttps://git.kernel.org/stable/c/73f9dccb29e4f82574bec2765c0090cdb0404301https://git.kernel.org/stable/c/84c0762633f2a7ac8399e6b97d3b9bb8e6e1d50fhttps://git.kernel.org/stable/c/b3d5d0983388d6c4fb35f7d722556d5595f167a7https://git.kernel.org/stable/c/b8b2f37cf632434456182e9002d63cbc4cccc50chttps://git.kernel.org/stable/c/e40c52ee67b155ad59f59e73ea136d02685f0e0d
2024-02-28
Published