7.8
HIGH CVSS 3.1
CVE-2024-42105
nilfs2: fix inode number range checks
Description

In the Linux kernel, the following vulnerability has been resolved: nilfs2: fix inode number range checks Patch series "nilfs2: fix potential issues related to reserved inodes". This series fixes one use-after-free issue reported by syzbot, caused by nilfs2's internal inode being exposed in the namespace on a corrupted filesystem, and a couple of flaws that cause problems if the starting number of non-reserved inodes written in the on-disk super block is intentionally (or corruptly) changed from its default value. This patch (of 3): In the current implementation of nilfs2, "nilfs->ns_first_ino", which gives the first non-reserved inode number, is read from the superblock, but its lower limit is not checked. As a result, if a number that overlaps with the inode number range of reserved inodes such as the root directory or metadata files is set in the super block parameter, the inode number test macros (NILFS_MDT_INODE and NILFS_VALID_INODE) will not function properly. In addition, these test macros use left bit-shift calculations using with the inode number as the shift count via the BIT macro, but the result of a shift calculation that exceeds the bit width of an integer is undefined in the C specification, so if "ns_first_ino" is set to a large value other than the default value NILFS_USER_INO (=11), the macros may potentially malfunction depending on the environment. Fix these issues by checking the lower bound of "nilfs->ns_first_ino" and by preventing bit shifts equal to or greater than the NILFS_USER_INO constant in the inode number test macros. Also, change the type of "ns_first_ino" from signed integer to unsigned integer to avoid the need for type casting in comparisons such as the lower bound check introduced this time.

INFO

Published Date :

July 30, 2024, 8:15 a.m.

Last Modified :

Sept. 26, 2025, 3:38 p.m.

Remotely Exploit :

No

Source :

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

The following products are affected by CVE-2024-42105 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
CVSS Scores
The Common Vulnerability Scoring System is a standardized framework for assessing the severity of vulnerabilities in software and systems. We collect and displays CVSS scores from various sources for each CVE.
Score Version Severity Vector Exploitability Score Impact Score Source
CVSS 3.1 HIGH [email protected]
Solution
Updating the Linux kernel packages will remediate the nilfs2 inode number range vulnerability.
  • Update the affected kernel packages.
  • Reboot the system if required by updates.
CWE - Common Weakness Enumeration

While CVE identifies specific instances of vulnerabilities, CWE categorizes the common flaws or weaknesses that can lead to vulnerabilities. CVE-2024-42105 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-2024-42105 weaknesses.

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

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

    Sep. 26, 2025

    Action Type Old Value New Value
    Added CVSS V3.1 AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
    Added CWE CWE-416
    Added CPE Configuration OR *cpe:2.3:o:linux:linux_kernel:6.10:rc2:*:*:*:*:*:* *cpe:2.3:o:linux:linux_kernel:6.10:rc3:*:*:*:*:*:* *cpe:2.3:o:linux:linux_kernel:6.10:rc4:*:*:*:*:*:* *cpe:2.3:o:linux:linux_kernel:6.10:rc5:*:*:*:*:*:* *cpe:2.3:o:linux:linux_kernel:6.10:rc1:*:*:*:*:*:* *cpe:2.3:o:linux:linux_kernel:6.10:rc6:*:*:*:*:*:* *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions up to (excluding) 4.19.318 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 4.20 up to (excluding) 5.4.280 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.5 up to (excluding) 5.10.222 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.11 up to (excluding) 5.15.163 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.16 up to (excluding) 6.1.98 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 6.2 up to (excluding) 6.6.39 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 6.7 up to (excluding) 6.9.9
    Added Reference Type CVE: https://git.kernel.org/stable/c/08cab183a624ba71603f3754643ae11cab34dbc4 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/08cab183a624ba71603f3754643ae11cab34dbc4 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/1c91058425a01131ea30dda6cf43c67b17884d6a Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/1c91058425a01131ea30dda6cf43c67b17884d6a Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/3be4dcc8d7bea52ea41f87aa4bbf959efe7a5987 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/3be4dcc8d7bea52ea41f87aa4bbf959efe7a5987 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/57235c3c88bb430043728d0d02f44a4efe386476 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/57235c3c88bb430043728d0d02f44a4efe386476 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/731011ac6c37cbe97ece229fc6daa486276052c5 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/731011ac6c37cbe97ece229fc6daa486276052c5 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/9194f8ca57527958bee207919458e372d638d783 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/9194f8ca57527958bee207919458e372d638d783 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/e2fec219a36e0993642844be0f345513507031f4 Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/e2fec219a36e0993642844be0f345513507031f4 Types: Patch
    Added Reference Type CVE: https://git.kernel.org/stable/c/fae1959d6ab2c52677b113935e36ab4e25df37ea Types: Patch
    Added Reference Type kernel.org: https://git.kernel.org/stable/c/fae1959d6ab2c52677b113935e36ab4e25df37ea Types: 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/08cab183a624ba71603f3754643ae11cab34dbc4
    Added Reference https://git.kernel.org/stable/c/1c91058425a01131ea30dda6cf43c67b17884d6a
    Added Reference https://git.kernel.org/stable/c/3be4dcc8d7bea52ea41f87aa4bbf959efe7a5987
    Added Reference https://git.kernel.org/stable/c/57235c3c88bb430043728d0d02f44a4efe386476
    Added Reference https://git.kernel.org/stable/c/731011ac6c37cbe97ece229fc6daa486276052c5
    Added Reference https://git.kernel.org/stable/c/9194f8ca57527958bee207919458e372d638d783
    Added Reference https://git.kernel.org/stable/c/e2fec219a36e0993642844be0f345513507031f4
    Added Reference https://git.kernel.org/stable/c/fae1959d6ab2c52677b113935e36ab4e25df37ea
  • CVE Received by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    Jul. 30, 2024

    Action Type Old Value New Value
    Added Description In the Linux kernel, the following vulnerability has been resolved: nilfs2: fix inode number range checks Patch series "nilfs2: fix potential issues related to reserved inodes". This series fixes one use-after-free issue reported by syzbot, caused by nilfs2's internal inode being exposed in the namespace on a corrupted filesystem, and a couple of flaws that cause problems if the starting number of non-reserved inodes written in the on-disk super block is intentionally (or corruptly) changed from its default value. This patch (of 3): In the current implementation of nilfs2, "nilfs->ns_first_ino", which gives the first non-reserved inode number, is read from the superblock, but its lower limit is not checked. As a result, if a number that overlaps with the inode number range of reserved inodes such as the root directory or metadata files is set in the super block parameter, the inode number test macros (NILFS_MDT_INODE and NILFS_VALID_INODE) will not function properly. In addition, these test macros use left bit-shift calculations using with the inode number as the shift count via the BIT macro, but the result of a shift calculation that exceeds the bit width of an integer is undefined in the C specification, so if "ns_first_ino" is set to a large value other than the default value NILFS_USER_INO (=11), the macros may potentially malfunction depending on the environment. Fix these issues by checking the lower bound of "nilfs->ns_first_ino" and by preventing bit shifts equal to or greater than the NILFS_USER_INO constant in the inode number test macros. Also, change the type of "ns_first_ino" from signed integer to unsigned integer to avoid the need for type casting in comparisons such as the lower bound check introduced this time.
    Added Reference kernel.org https://git.kernel.org/stable/c/57235c3c88bb430043728d0d02f44a4efe386476 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/08cab183a624ba71603f3754643ae11cab34dbc4 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/731011ac6c37cbe97ece229fc6daa486276052c5 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/3be4dcc8d7bea52ea41f87aa4bbf959efe7a5987 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/fae1959d6ab2c52677b113935e36ab4e25df37ea [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/9194f8ca57527958bee207919458e372d638d783 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/1c91058425a01131ea30dda6cf43c67b17884d6a [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/e2fec219a36e0993642844be0f345513507031f4 [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.
Vulnerability Scoring Details
Base CVSS Score: 7.8
Attack Vector
Attack Complexity
Privileges Required
User Interaction
Scope
Confidentiality Impact
Integrity Impact
Availability Impact