CVE-2021-47338
"QEMU KVM buffer overwrite"
Description
In the Linux kernel, the following vulnerability has been resolved: fbmem: Do not delete the mode that is still in use The execution of fb_delete_videomode() is not based on the result of the previous fbcon_mode_deleted(). As a result, the mode is directly deleted, regardless of whether it is still in use, which may cause UAF. ================================================================== BUG: KASAN: use-after-free in fb_mode_is_equal+0x36e/0x5e0 \ drivers/video/fbdev/core/modedb.c:924 Read of size 4 at addr ffff88807e0ddb1c by task syz-executor.0/18962 CPU: 2 PID: 18962 Comm: syz-executor.0 Not tainted 5.10.45-rc1+ #3 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS ... Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x137/0x1be lib/dump_stack.c:118 print_address_description+0x6c/0x640 mm/kasan/report.c:385 __kasan_report mm/kasan/report.c:545 [inline] kasan_report+0x13d/0x1e0 mm/kasan/report.c:562 fb_mode_is_equal+0x36e/0x5e0 drivers/video/fbdev/core/modedb.c:924 fbcon_mode_deleted+0x16a/0x220 drivers/video/fbdev/core/fbcon.c:2746 fb_set_var+0x1e1/0xdb0 drivers/video/fbdev/core/fbmem.c:975 do_fb_ioctl+0x4d9/0x6e0 drivers/video/fbdev/core/fbmem.c:1108 vfs_ioctl fs/ioctl.c:48 [inline] __do_sys_ioctl fs/ioctl.c:753 [inline] __se_sys_ioctl+0xfb/0x170 fs/ioctl.c:739 do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 Freed by task 18960: kasan_save_stack mm/kasan/common.c:48 [inline] kasan_set_track+0x3d/0x70 mm/kasan/common.c:56 kasan_set_free_info+0x17/0x30 mm/kasan/generic.c:355 __kasan_slab_free+0x108/0x140 mm/kasan/common.c:422 slab_free_hook mm/slub.c:1541 [inline] slab_free_freelist_hook+0xd6/0x1a0 mm/slub.c:1574 slab_free mm/slub.c:3139 [inline] kfree+0xca/0x3d0 mm/slub.c:4121 fb_delete_videomode+0x56a/0x820 drivers/video/fbdev/core/modedb.c:1104 fb_set_var+0x1f3/0xdb0 drivers/video/fbdev/core/fbmem.c:978 do_fb_ioctl+0x4d9/0x6e0 drivers/video/fbdev/core/fbmem.c:1108 vfs_ioctl fs/ioctl.c:48 [inline] __do_sys_ioctl fs/ioctl.c:753 [inline] __se_sys_ioctl+0xfb/0x170 fs/ioctl.c:739 do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9
INFO
Published Date :
May 21, 2024, 3:15 p.m.
Last Modified :
Dec. 24, 2024, 4:39 p.m.
Source :
416baaa9-dc9f-4396-8d5f-8c081fb06d67
Remotely Exploitable :
No
Impact Score :
5.9
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-2021-47338
.
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-2021-47338
vulnerability anywhere in the article.
The following table lists the changes that have been made to the
CVE-2021-47338
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]
Dec. 24, 2024
Action Type Old Value New Value Added CVSS V3.1 NIST AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H Added CWE NIST CWE-416 Added CPE Configuration OR *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.3 up to (excluding) 5.4.134 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.5 up to (excluding) 5.10.52 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.11 up to (excluding) 5.12.19 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.13 up to (excluding) 5.13.4 *cpe:2.3:o:linux:linux_kernel:5.14:rc1:*:*:*:*:*:* Changed Reference Type https://git.kernel.org/stable/c/087bff9acd2ec6db3f61aceb3224bde90fe0f7f8 No Types Assigned https://git.kernel.org/stable/c/087bff9acd2ec6db3f61aceb3224bde90fe0f7f8 Patch Changed Reference Type https://git.kernel.org/stable/c/087bff9acd2ec6db3f61aceb3224bde90fe0f7f8 No Types Assigned https://git.kernel.org/stable/c/087bff9acd2ec6db3f61aceb3224bde90fe0f7f8 Patch Changed Reference Type https://git.kernel.org/stable/c/0af778269a522c988ef0b4188556aba97fb420cc No Types Assigned https://git.kernel.org/stable/c/0af778269a522c988ef0b4188556aba97fb420cc Patch Changed Reference Type https://git.kernel.org/stable/c/0af778269a522c988ef0b4188556aba97fb420cc No Types Assigned https://git.kernel.org/stable/c/0af778269a522c988ef0b4188556aba97fb420cc Patch Changed Reference Type https://git.kernel.org/stable/c/359311b85ebec7c07c3a08ae2f3def946cad33fa No Types Assigned https://git.kernel.org/stable/c/359311b85ebec7c07c3a08ae2f3def946cad33fa Patch Changed Reference Type https://git.kernel.org/stable/c/359311b85ebec7c07c3a08ae2f3def946cad33fa No Types Assigned https://git.kernel.org/stable/c/359311b85ebec7c07c3a08ae2f3def946cad33fa Patch Changed Reference Type https://git.kernel.org/stable/c/d6e76469157d8f240e5dec6f8411aa8d306b1126 No Types Assigned https://git.kernel.org/stable/c/d6e76469157d8f240e5dec6f8411aa8d306b1126 Patch Changed Reference Type https://git.kernel.org/stable/c/d6e76469157d8f240e5dec6f8411aa8d306b1126 No Types Assigned https://git.kernel.org/stable/c/d6e76469157d8f240e5dec6f8411aa8d306b1126 Patch Changed Reference Type https://git.kernel.org/stable/c/f193509afc7ff37a46862610c93b896044d5b693 No Types Assigned https://git.kernel.org/stable/c/f193509afc7ff37a46862610c93b896044d5b693 Patch Changed Reference Type https://git.kernel.org/stable/c/f193509afc7ff37a46862610c93b896044d5b693 No Types Assigned https://git.kernel.org/stable/c/f193509afc7ff37a46862610c93b896044d5b693 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/087bff9acd2ec6db3f61aceb3224bde90fe0f7f8 Added Reference https://git.kernel.org/stable/c/0af778269a522c988ef0b4188556aba97fb420cc Added Reference https://git.kernel.org/stable/c/359311b85ebec7c07c3a08ae2f3def946cad33fa Added Reference https://git.kernel.org/stable/c/d6e76469157d8f240e5dec6f8411aa8d306b1126 Added Reference https://git.kernel.org/stable/c/f193509afc7ff37a46862610c93b896044d5b693 -
CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67
May. 28, 2024
Action Type Old Value New Value -
CVE Received by 416baaa9-dc9f-4396-8d5f-8c081fb06d67
May. 21, 2024
Action Type Old Value New Value Added Description In the Linux kernel, the following vulnerability has been resolved: fbmem: Do not delete the mode that is still in use The execution of fb_delete_videomode() is not based on the result of the previous fbcon_mode_deleted(). As a result, the mode is directly deleted, regardless of whether it is still in use, which may cause UAF. ================================================================== BUG: KASAN: use-after-free in fb_mode_is_equal+0x36e/0x5e0 \ drivers/video/fbdev/core/modedb.c:924 Read of size 4 at addr ffff88807e0ddb1c by task syz-executor.0/18962 CPU: 2 PID: 18962 Comm: syz-executor.0 Not tainted 5.10.45-rc1+ #3 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS ... Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x137/0x1be lib/dump_stack.c:118 print_address_description+0x6c/0x640 mm/kasan/report.c:385 __kasan_report mm/kasan/report.c:545 [inline] kasan_report+0x13d/0x1e0 mm/kasan/report.c:562 fb_mode_is_equal+0x36e/0x5e0 drivers/video/fbdev/core/modedb.c:924 fbcon_mode_deleted+0x16a/0x220 drivers/video/fbdev/core/fbcon.c:2746 fb_set_var+0x1e1/0xdb0 drivers/video/fbdev/core/fbmem.c:975 do_fb_ioctl+0x4d9/0x6e0 drivers/video/fbdev/core/fbmem.c:1108 vfs_ioctl fs/ioctl.c:48 [inline] __do_sys_ioctl fs/ioctl.c:753 [inline] __se_sys_ioctl+0xfb/0x170 fs/ioctl.c:739 do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 Freed by task 18960: kasan_save_stack mm/kasan/common.c:48 [inline] kasan_set_track+0x3d/0x70 mm/kasan/common.c:56 kasan_set_free_info+0x17/0x30 mm/kasan/generic.c:355 __kasan_slab_free+0x108/0x140 mm/kasan/common.c:422 slab_free_hook mm/slub.c:1541 [inline] slab_free_freelist_hook+0xd6/0x1a0 mm/slub.c:1574 slab_free mm/slub.c:3139 [inline] kfree+0xca/0x3d0 mm/slub.c:4121 fb_delete_videomode+0x56a/0x820 drivers/video/fbdev/core/modedb.c:1104 fb_set_var+0x1f3/0xdb0 drivers/video/fbdev/core/fbmem.c:978 do_fb_ioctl+0x4d9/0x6e0 drivers/video/fbdev/core/fbmem.c:1108 vfs_ioctl fs/ioctl.c:48 [inline] __do_sys_ioctl fs/ioctl.c:753 [inline] __se_sys_ioctl+0xfb/0x170 fs/ioctl.c:739 do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 Added Reference kernel.org https://git.kernel.org/stable/c/359311b85ebec7c07c3a08ae2f3def946cad33fa [No types assigned] Added Reference kernel.org https://git.kernel.org/stable/c/087bff9acd2ec6db3f61aceb3224bde90fe0f7f8 [No types assigned] Added Reference kernel.org https://git.kernel.org/stable/c/f193509afc7ff37a46862610c93b896044d5b693 [No types assigned] Added Reference kernel.org https://git.kernel.org/stable/c/d6e76469157d8f240e5dec6f8411aa8d306b1126 [No types assigned] Added Reference kernel.org https://git.kernel.org/stable/c/0af778269a522c988ef0b4188556aba97fb420cc [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-2021-47338
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-2021-47338
weaknesses.