5.5
MEDIUM
CVE-2023-52622
Linux ext4 flexbg Size Overflow Vulnerability
Description

In the Linux kernel, the following vulnerability has been resolved: ext4: avoid online resizing failures due to oversized flex bg When we online resize an ext4 filesystem with a oversized flexbg_size, mkfs.ext4 -F -G 67108864 $dev -b 4096 100M mount $dev $dir resize2fs $dev 16G the following WARN_ON is triggered: ================================================================== WARNING: CPU: 0 PID: 427 at mm/page_alloc.c:4402 __alloc_pages+0x411/0x550 Modules linked in: sg(E) CPU: 0 PID: 427 Comm: resize2fs Tainted: G E 6.6.0-rc5+ #314 RIP: 0010:__alloc_pages+0x411/0x550 Call Trace: <TASK> __kmalloc_large_node+0xa2/0x200 __kmalloc+0x16e/0x290 ext4_resize_fs+0x481/0xd80 __ext4_ioctl+0x1616/0x1d90 ext4_ioctl+0x12/0x20 __x64_sys_ioctl+0xf0/0x150 do_syscall_64+0x3b/0x90 ================================================================== This is because flexbg_size is too large and the size of the new_group_data array to be allocated exceeds MAX_ORDER. Currently, the minimum value of MAX_ORDER is 8, the minimum value of PAGE_SIZE is 4096, the corresponding maximum number of groups that can be allocated is: (PAGE_SIZE << MAX_ORDER) / sizeof(struct ext4_new_group_data) ≈ 21845 And the value that is down-aligned to the power of 2 is 16384. Therefore, this value is defined as MAX_RESIZE_BG, and the number of groups added each time does not exceed this value during resizing, and is added multiple times to complete the online resizing. The difference is that the metadata in a flex_bg may be more dispersed.

INFO

Published Date :

March 26, 2024, 6:15 p.m.

Last Modified :

March 17, 2025, 3:19 p.m.

Source :

416baaa9-dc9f-4396-8d5f-8c081fb06d67

Remotely Exploitable :

No

Impact Score :

3.6

Exploitability Score :

1.8
Affected Products

The following products are affected by CVE-2023-52622 vulnerability. Even if cvefeed.io is aware of the exact versions of the products that are affected, the information is not represented in the table below.

ID Vendor Product Action
1 Linux linux_kernel
1 Debian debian_linux
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-52622.

URL Resource
https://git.kernel.org/stable/c/5d1935ac02ca5aee364a449a35e2977ea84509b0 Patch
https://git.kernel.org/stable/c/6d2cbf517dcabc093159cf138ad5712c9c7fa954 Patch
https://git.kernel.org/stable/c/8b1413dbfe49646eda2c00c0f1144ee9d3368e0c Patch
https://git.kernel.org/stable/c/b183fe8702e78bba3dcef8e7193cab6898abee07 Patch
https://git.kernel.org/stable/c/cd1f93ca97a9136989f3bd2bf90696732a2ed644 Patch
https://git.kernel.org/stable/c/cfbbb3199e71b63fc26cee0ebff327c47128a1e8 Patch
https://git.kernel.org/stable/c/d76c8d7ffe163c6bf2f1ef680b0539c2b3902b90 Patch
https://git.kernel.org/stable/c/dc3e0f55bec4410f3d74352c4a7c79f518088ee2 Patch
https://git.kernel.org/stable/c/5d1935ac02ca5aee364a449a35e2977ea84509b0 Patch
https://git.kernel.org/stable/c/6d2cbf517dcabc093159cf138ad5712c9c7fa954 Patch
https://git.kernel.org/stable/c/8b1413dbfe49646eda2c00c0f1144ee9d3368e0c Patch
https://git.kernel.org/stable/c/b183fe8702e78bba3dcef8e7193cab6898abee07 Patch
https://git.kernel.org/stable/c/cd1f93ca97a9136989f3bd2bf90696732a2ed644 Patch
https://git.kernel.org/stable/c/cfbbb3199e71b63fc26cee0ebff327c47128a1e8 Patch
https://git.kernel.org/stable/c/d76c8d7ffe163c6bf2f1ef680b0539c2b3902b90 Patch
https://git.kernel.org/stable/c/dc3e0f55bec4410f3d74352c4a7c79f518088ee2 Patch
https://lists.debian.org/debian-lts-announce/2024/06/msg00017.html Mailing List
https://lists.debian.org/debian-lts-announce/2024/06/msg00020.html Mailing List

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-52622 vulnerability anywhere in the article.

The following table lists the changes that have been made to the CVE-2023-52622 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]

    Mar. 17, 2025

    Action Type Old Value New Value
    Added CVSS V3.1 AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
    Added CWE CWE-770
    Added CPE Configuration OR *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.11 from (excluding) 5.15.149 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.5 from (excluding) 5.10.210 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 6.7 from (excluding) 6.7.4 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 6.2 from (excluding) 6.6.16 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.16 from (excluding) 6.1.77 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 4.20 from (excluding) 5.4.269 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (excluding) 4.19.307
    Added CPE Configuration OR *cpe:2.3:o:debian:debian_linux:10.0:*:*:*:*:*:*:*
    Added Reference Type CVE: https://git.kernel.org/stable/c/5d1935ac02ca5aee364a449a35e2977ea84509b0 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/5d1935ac02ca5aee364a449a35e2977ea84509b0 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/6d2cbf517dcabc093159cf138ad5712c9c7fa954 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/6d2cbf517dcabc093159cf138ad5712c9c7fa954 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/8b1413dbfe49646eda2c00c0f1144ee9d3368e0c Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/8b1413dbfe49646eda2c00c0f1144ee9d3368e0c Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/b183fe8702e78bba3dcef8e7193cab6898abee07 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/b183fe8702e78bba3dcef8e7193cab6898abee07 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/cd1f93ca97a9136989f3bd2bf90696732a2ed644 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/cd1f93ca97a9136989f3bd2bf90696732a2ed644 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/cfbbb3199e71b63fc26cee0ebff327c47128a1e8 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/cfbbb3199e71b63fc26cee0ebff327c47128a1e8 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/d76c8d7ffe163c6bf2f1ef680b0539c2b3902b90 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/d76c8d7ffe163c6bf2f1ef680b0539c2b3902b90 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/dc3e0f55bec4410f3d74352c4a7c79f518088ee2 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/dc3e0f55bec4410f3d74352c4a7c79f518088ee2 Types: Patch
    Added Reference Type CVE: https://lists.debian.org/debian-lts-announce/2024/06/msg00017.html Types: Mailing List
    Added Reference Type CVE: https://lists.debian.org/debian-lts-announce/2024/06/msg00020.html Types: Mailing List
  • 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/5d1935ac02ca5aee364a449a35e2977ea84509b0
    Added Reference https://git.kernel.org/stable/c/6d2cbf517dcabc093159cf138ad5712c9c7fa954
    Added Reference https://git.kernel.org/stable/c/8b1413dbfe49646eda2c00c0f1144ee9d3368e0c
    Added Reference https://git.kernel.org/stable/c/b183fe8702e78bba3dcef8e7193cab6898abee07
    Added Reference https://git.kernel.org/stable/c/cd1f93ca97a9136989f3bd2bf90696732a2ed644
    Added Reference https://git.kernel.org/stable/c/cfbbb3199e71b63fc26cee0ebff327c47128a1e8
    Added Reference https://git.kernel.org/stable/c/d76c8d7ffe163c6bf2f1ef680b0539c2b3902b90
    Added Reference https://git.kernel.org/stable/c/dc3e0f55bec4410f3d74352c4a7c79f518088ee2
    Added Reference https://lists.debian.org/debian-lts-announce/2024/06/msg00017.html
    Added Reference https://lists.debian.org/debian-lts-announce/2024/06/msg00020.html
  • CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    Nov. 04, 2024

    Action Type Old Value New Value
    Removed Reference kernel.org https://lists.debian.org/debian-lts-announce/2024/06/msg00017.html
    Removed Reference kernel.org https://lists.debian.org/debian-lts-announce/2024/06/msg00020.html
  • CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    Jun. 27, 2024

    Action Type Old Value New Value
    Added Reference kernel.org https://lists.debian.org/debian-lts-announce/2024/06/msg00020.html [No types assigned]
  • CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    Jun. 25, 2024

    Action Type Old Value New Value
    Added Reference kernel.org https://lists.debian.org/debian-lts-announce/2024/06/msg00017.html [No types assigned]
  • CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    May. 29, 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 Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    Apr. 11, 2024

    Action Type Old Value New Value
    Changed Description In the Linux kernel, the following vulnerability has been resolved: ext4: avoid online resizing failures due to oversized flex bg When we online resize an ext4 filesystem with a oversized flexbg_size, mkfs.ext4 -F -G 67108864 $dev -b 4096 100M mount $dev $dir resize2fs $dev 16G the following WARN_ON is triggered: ================================================================== WARNING: CPU: 0 PID: 427 at mm/page_alloc.c:4402 __alloc_pages+0x411/0x550 Modules linked in: sg(E) CPU: 0 PID: 427 Comm: resize2fs Tainted: G E 6.6.0-rc5+ #314 RIP: 0010:__alloc_pages+0x411/0x550 Call Trace: <TASK> __kmalloc_large_node+0xa2/0x200 __kmalloc+0x16e/0x290 ext4_resize_fs+0x481/0xd80 __ext4_ioctl+0x1616/0x1d90 ext4_ioctl+0x12/0x20 __x64_sys_ioctl+0xf0/0x150 do_syscall_64+0x3b/0x90 ================================================================== This is because flexbg_size is too large and the size of the new_group_data array to be allocated exceeds MAX_ORDER. Currently, the minimum value of MAX_ORDER is 8, the minimum value of PAGE_SIZE is 4096, the corresponding maximum number of groups that can be allocated is: (PAGE_SIZE << MAX_ORDER) / sizeof(struct ext4_new_group_data) ? 21845 And the value that is down-aligned to the power of 2 is 16384. Therefore, this value is defined as MAX_RESIZE_BG, and the number of groups added each time does not exceed this value during resizing, and is added multiple times to complete the online resizing. The difference is that the metadata in a flex_bg may be more dispersed. In the Linux kernel, the following vulnerability has been resolved: ext4: avoid online resizing failures due to oversized flex bg When we online resize an ext4 filesystem with a oversized flexbg_size, mkfs.ext4 -F -G 67108864 $dev -b 4096 100M mount $dev $dir resize2fs $dev 16G the following WARN_ON is triggered: ================================================================== WARNING: CPU: 0 PID: 427 at mm/page_alloc.c:4402 __alloc_pages+0x411/0x550 Modules linked in: sg(E) CPU: 0 PID: 427 Comm: resize2fs Tainted: G E 6.6.0-rc5+ #314 RIP: 0010:__alloc_pages+0x411/0x550 Call Trace: <TASK> __kmalloc_large_node+0xa2/0x200 __kmalloc+0x16e/0x290 ext4_resize_fs+0x481/0xd80 __ext4_ioctl+0x1616/0x1d90 ext4_ioctl+0x12/0x20 __x64_sys_ioctl+0xf0/0x150 do_syscall_64+0x3b/0x90 ================================================================== This is because flexbg_size is too large and the size of the new_group_data array to be allocated exceeds MAX_ORDER. Currently, the minimum value of MAX_ORDER is 8, the minimum value of PAGE_SIZE is 4096, the corresponding maximum number of groups that can be allocated is: (PAGE_SIZE << MAX_ORDER) / sizeof(struct ext4_new_group_data) ≈ 21845 And the value that is down-aligned to the power of 2 is 16384. Therefore, this value is defined as MAX_RESIZE_BG, and the number of groups added each time does not exceed this value during resizing, and is added multiple times to complete the online resizing. The difference is that the metadata in a flex_bg may be more dispersed.
  • CVE Received by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    Mar. 26, 2024

    Action Type Old Value New Value
    Added Description In the Linux kernel, the following vulnerability has been resolved: ext4: avoid online resizing failures due to oversized flex bg When we online resize an ext4 filesystem with a oversized flexbg_size, mkfs.ext4 -F -G 67108864 $dev -b 4096 100M mount $dev $dir resize2fs $dev 16G the following WARN_ON is triggered: ================================================================== WARNING: CPU: 0 PID: 427 at mm/page_alloc.c:4402 __alloc_pages+0x411/0x550 Modules linked in: sg(E) CPU: 0 PID: 427 Comm: resize2fs Tainted: G E 6.6.0-rc5+ #314 RIP: 0010:__alloc_pages+0x411/0x550 Call Trace: <TASK> __kmalloc_large_node+0xa2/0x200 __kmalloc+0x16e/0x290 ext4_resize_fs+0x481/0xd80 __ext4_ioctl+0x1616/0x1d90 ext4_ioctl+0x12/0x20 __x64_sys_ioctl+0xf0/0x150 do_syscall_64+0x3b/0x90 ================================================================== This is because flexbg_size is too large and the size of the new_group_data array to be allocated exceeds MAX_ORDER. Currently, the minimum value of MAX_ORDER is 8, the minimum value of PAGE_SIZE is 4096, the corresponding maximum number of groups that can be allocated is: (PAGE_SIZE << MAX_ORDER) / sizeof(struct ext4_new_group_data) ≈ 21845 And the value that is down-aligned to the power of 2 is 16384. Therefore, this value is defined as MAX_RESIZE_BG, and the number of groups added each time does not exceed this value during resizing, and is added multiple times to complete the online resizing. The difference is that the metadata in a flex_bg may be more dispersed.
    Added Reference kernel.org https://git.kernel.org/stable/c/cd1f93ca97a9136989f3bd2bf90696732a2ed644 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/b183fe8702e78bba3dcef8e7193cab6898abee07 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/cfbbb3199e71b63fc26cee0ebff327c47128a1e8 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/d76c8d7ffe163c6bf2f1ef680b0539c2b3902b90 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/6d2cbf517dcabc093159cf138ad5712c9c7fa954 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/8b1413dbfe49646eda2c00c0f1144ee9d3368e0c [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/dc3e0f55bec4410f3d74352c4a7c79f518088ee2 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/5d1935ac02ca5aee364a449a35e2977ea84509b0 [No types assigned]
EPSS is a daily estimate of the probability of exploitation activity being observed over the next 30 days. Following chart shows the EPSS score history of the vulnerability.
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-52622 is associated with the following CWEs:

CVSS31 - Vulnerability Scoring System
Attack Vector
Attack Complexity
Privileges Required
User Interaction
Scope
Confidentiality
Integrity
Availability