CVE-2024-40998

Updated:

Description:

In the Linux kernel, the following vulnerability has been resolved: ext4: fix uninitialized ratelimit_state->lock access in __ext4_fill_super() In the following concurrency we will access the uninitialized rs->lock: ext4_fill_super ext4_register_sysfs // sysfs registered msg_ratelimit_interval_ms // Other processes modify rs->interval to // non-zero via msg_ratelimit_interval_ms ext4_orphan_cleanup ext4_msg(sb, KERN_INFO, "Errors on filesystem, " __ext4_msg ___ratelimit(&(EXT4_SB(sb)->s_msg_ratelimit_state) if (!rs->interval) // do nothing if interval is 0 return 1; raw_spin_trylock_irqsave(&rs->lock, flags) raw_spin_trylock(lock) _raw_spin_trylock __raw_spin_trylock spin_acquire(&lock->dep_map, 0, 1, _RET_IP_) lock_acquire __lock_acquire register_lock_class assign_lock_key dump_stack(); ratelimit_state_init(&sbi->s_msg_ratelimit_state, 5 * HZ, 10); raw_spin_lock_init(&rs->lock); // init rs->lock here and get the following dump_stack: ========================================================= INFO: trying to register non-static key. The code is fine but needs lockdep annotation, or maybe you didn't initialize this object before use? turning off the locking correctness validator. CPU: 12 PID: 753 Comm: mount Tainted: G E 6.7.0-rc6-next-20231222 #504 [...] Call Trace: dump_stack_lvl+0xc5/0x170 dump_stack+0x18/0x30 register_lock_class+0x740/0x7c0 __lock_acquire+0x69/0x13a0 lock_acquire+0x120/0x450 _raw_spin_trylock+0x98/0xd0 ___ratelimit+0xf6/0x220 __ext4_msg+0x7f/0x160 [ext4] ext4_orphan_cleanup+0x665/0x740 [ext4] __ext4_fill_super+0x21ea/0x2b10 [ext4] ext4_fill_super+0x14d/0x360 [ext4] [...] ========================================================= Normally interval is 0 until s_msg_ratelimit_state is initialized, so ___ratelimit() does nothing. But registering sysfs precedes initializing rs->lock, so it is possible to change rs->interval to a non-zero value via the msg_ratelimit_interval_ms interface of sysfs while rs->lock is uninitialized, and then a call to ext4_msg triggers the problem by accessing an uninitialized rs->lock. Therefore register sysfs after all initializations are complete to avoid such problems.

CVSS3: 5.5


Vendor State

OS Vendor version Errata
RHEL 8 4.18.0-553.22.1.el8_10 RHSA-2024:7000
Oracle Linux 8 4.18.0-553.22.1.el8_10 ELSA-2024-7000
AlmaLinux 8 4.18.0-553.22.1.el8_10 ALSA-2024:7000
Rocky Linux 8 4.18.0-553.22.1.el8_10 RLSA-2024:7000
RHEL 9 5.14.0-427.42.1.el9_4 RHSA-2024:8617
Oracle Linux 9 5.14.0-427.42.1.el9_4 ELSA-2024-8617
Rocky Linux 9 5.14.0-427.42.1.el9_4 RLSA-2024:8617
AlmaLinux 9 5.14.0-427.42.1.el9_4 ALSA-2024:8617
RHEL8 EUS 8.6 4.18.0-372.127.1.el8_6 RHSA-2024:8616
Ubuntu 24.04 6.8.0-44.44 USN-6999-1

KernelCare State

OS Original kernel version State
RHEL 8
4.18.0-147.el8 show all hide all
4.18.0-80.11.1.el8_0 4.18.0-80.4.2.el8_0 4.18.0-80.11.2.el8_0 4.18.0-80.7.2.el8_0 4.18.0-80.7.1.el8_0 4.18.0-147.0.2.el8_1 4.18.0-80.1.2.el8_0 4.18.0-147.0.3.el8_1 4.18.0-80.el8 4.18.0-147.5.1.el8_1 4.18.0-147.3.1.el8_1 4.18.0-147.8.1.el8_1 4.18.0-193.el8 4.18.0-193.1.2.el8_2 4.18.0-193.6.3.el8_2 4.18.0-193.13.2.el8_2 4.18.0-193.14.3.el8_2 4.18.0-193.19.1.el8_2 4.18.0-193.28.1.el8_2 4.18.0-240.el8 4.18.0-240.1.1.el8_3 4.18.0-240.8.1.el8_3 4.18.0-240.10.1.el8_3 4.18.0-240.15.1.el8_3 4.18.0-240.22.1.el8_3 4.18.0-305.el8 4.18.0-305.3.1.el8_4 4.18.0-305.7.1.el8_4 4.18.0-305.10.2.el8_4 4.18.0-305.12.1.el8_4 4.18.0-305.17.1.el8_4 4.18.0-305.19.1.el8_4 4.18.0-305.25.1.el8_4 4.18.0-348.el8 4.18.0-348.2.1.el8_5 4.18.0-348.7.1.el8_5 4.18.0-348.12.2.el8_5 4.18.0-348.20.1.el8_5 4.18.0-372.9.1.el8 4.18.0-348.23.1.el8_5 4.18.0-372.13.1.el8_6 4.18.0-372.16.1.el8_6 4.18.0-372.19.1.el8_6 4.18.0-372.26.1.el8_6 4.18.0-372.32.1.el8_6 4.18.0-425.3.1.el8 4.18.0-425.10.1.el8_7 4.18.0-425.13.1.el8_7 4.18.0-425.19.2.el8_7 4.18.0-477.10.1.el8_8 4.18.0-477.13.1.el8_8 4.18.0-477.15.1.el8_8 4.18.0-477.21.1.el8_8 4.18.0-477.27.1.el8_8 4.18.0-513.5.1.el8_9 4.18.0-513.9.1.el8_9 4.18.0-513.11.1.el8_9 4.18.0-513.18.1.el8_9 4.18.0-513.24.1.el8_9 4.18.0-553.el8_10 4.18.0-553.5.1.el8_10 4.18.0-553.8.1.el8_10 4.18.0-553.16.1.el8_10
Released
Oracle Linux 8
4.18.0-147.el8 show all hide all
4.18.0-80.11.1.el8_0 4.18.0-80.4.2.el8_0 4.18.0-147.5.1.el8_1 4.18.0-80.11.2.el8_0 4.18.0-80.7.2.el8_0 4.18.0-80.7.1.el8_0 4.18.0-147.0.2.el8_1 4.18.0-80.1.2.el8_0 4.18.0-147.0.3.el8_1 4.18.0-147.3.1.el8_1 4.18.0-80.el8 4.18.0-147.8.1.el8_1 4.18.0-193.1.2.el8_2 4.18.0-193.el8 4.18.0-193.6.3.el8_2 4.18.0-193.13.2.el8_2 4.18.0-193.14.3.el8_2 4.18.0-193.19.1.el8_2 4.18.0-193.28.1.el8_2 4.18.0-240.el8 4.18.0-240.1.1.el8_3 4.18.0-240.8.1.el8_3 4.18.0-240.10.1.el8_3 4.18.0-240.15.1.el8_3 4.18.0-240.22.1.el8_3 4.18.0-305.el8 4.18.0-305.3.1.el8_4 4.18.0-305.7.1.el8_4 4.18.0-305.10.2.el8_4 4.18.0-305.12.1.el8_4 4.18.0-305.17.1.el8_4 4.18.0-305.19.1.el8_4 4.18.0-305.25.1.el8_4 4.18.0-348.el8 4.18.0-348.2.1.el8_5 4.18.0-348.7.1.el8_5 4.18.0-348.12.2.el8_5 4.18.0-348.20.1.el8_5 4.18.0-348.23.1.el8_5 4.18.0-372.9.1.el8 4.18.0-372.13.1.0.1.el8_6 4.18.0-372.16.1.0.1.el8_6 4.18.0-372.19.1.0.1.el8_6 4.18.0-372.26.1.0.1.el8_6 4.18.0-372.32.1.0.1.el8_6 4.18.0-425.3.1.el8 4.18.0-425.10.1.el8_7 4.18.0-425.13.1.el8_7 4.18.0-425.19.2.el8_7 4.18.0-477.10.1.el8_8 4.18.0-477.13.1.el8_8 4.18.0-477.15.1.el8_8 4.18.0-477.21.1.el8_8 4.18.0-477.27.0.1.el8_8 4.18.0-477.27.1.el8_8 4.18.0-513.5.1.el8_9 4.18.0-513.9.1.el8_9 4.18.0-513.11.0.1.el8_9 4.18.0-513.18.0.1.el8_9 4.18.0-513.18.0.2.el8_9 4.18.0-513.18.1.el8_9 4.18.0-513.18.1.0.1.el8_9 4.18.0-513.24.1.el8_9 4.18.0-553.el8_10 4.18.0-553.5.1.el8_10 4.18.0-553.8.1.el8_10 4.18.0-553.16.1.el8_10
Released
CloudLinux OS 8
4.18.0-147.3.1.el8.lve.1 show all hide all
4.18.0-147.8.1.el8.lve 4.18.0-147.0.3.lve.el8 4.18.0-147.8.1.el8.lve.1 4.18.0-193.28.1.lve1.el8 4.18.0-305.lve.el8 4.18.0-305.7.1.lve.el8 4.18.0-305.10.2.lve.el8 4.18.0-305.10.2.2.lve.el8 4.18.0-305.12.1.lve.el8 4.18.0-305.17.1.lve.el8 4.18.0-305.19.1.lve.el8 4.18.0-348.lve.el8 4.18.0-348.7.1.lve.el8 4.18.0-348.12.2.lve.el8 4.18.0-348.20.1.lve.1.el8 4.18.0-348.20.1.lve.el8 4.18.0-348.23.1.lve.el8 4.18.0-372.9.1.1.lve.el8 4.18.0-372.16.1.lve.el8 4.18.0-372.9.1.lve.el8 4.18.0-372.19.1.lve.el8 4.18.0-372.13.1.lve.el8 4.18.0-372.26.1.lve.1.el8 4.18.0-372.32.1.lve.el8 4.18.0-425.3.1.lve.1.el8 4.18.0-425.3.1.lve.el8 4.18.0-425.3.1.lve.2.el8 4.18.0-425.3.1.lve.3.el8 4.18.0-425.10.1.lve.el8 4.18.0-425.13.1.lve.el8 4.18.0-425.19.2.lve.el8 4.18.0-477.10.1.lve.el8 4.18.0-477.13.1.lve.el8 4.18.0-477.15.1.lve.2.el8 4.18.0-477.13.1.lve.1.el8 4.18.0-477.21.1.lve.el8 4.18.0-477.21.1.lve.1.el8 4.18.0-477.27.1.lve.el8 4.18.0-477.27.2.lve.el8 4.18.0-513.5.1.lve.el8 4.18.0-513.9.1.lve.el8 4.18.0-513.11.1.lve.el8 4.18.0-513.18.1.lve.el8 4.18.0-513.18.1.lve.2.el8 4.18.0-513.18.1.lve.1.el8 4.18.0-513.24.1.lve.el8 4.18.0-513.24.1.lve.1.el8 4.18.0-553.lve.el8 4.18.0-513.24.1.lve.2.el8 4.18.0-553.5.1.lve.el8 4.18.0-544.lve.el8 4.18.0-553.5.1.lve.1.el8 4.18.0-553.8.1.lve.el8 4.18.0-553.16.1.lve.el8 4.18.0-553.16.1.lve.1.el8
Released
CloudLinux OS 7h
4.18.0-147.0.3.el7h.lve show all hide all
4.18.0-147.0.3.el7h 4.18.0-147.3.1.el7h.lve.1 4.18.0-147.8.1.el7h.lve 4.18.0-80.7.2.el7h 4.18.0-147.8.1.el7h.lve.1 4.18.0-193.28.1.lve1.el7h 4.18.0-305.lve.el7h 4.18.0-305.7.1.lve.el7h 4.18.0-305.10.2.lve.el7h 4.18.0-305.10.2.2.lve.el7h 4.18.0-305.12.1.lve.el7h 4.18.0-305.17.1.lve.el7h 4.18.0-305.19.1.lve.el7h 4.18.0-348.7.1.lve.el7h 4.18.0-348.12.2.lve.el7h 4.18.0-348.lve.el7h 4.18.0-348.12.2.lve.1.el7h 4.18.0-348.12.2.lve.2.el7h 4.18.0-348.20.1.lve.el7h 4.18.0-348.20.1.lve.1.el7h 4.18.0-348.23.1.lve.el7h 4.18.0-372.9.1.lve.el7h 4.18.0-372.13.1.lve.el7h 4.18.0-372.16.1.lve.el7h 4.18.0-372.19.1.lve.el7h 4.18.0-372.26.1.lve.1.el7h 4.18.0-372.32.1.lve.el7h 4.18.0-425.3.1.lve.el7h 4.18.0-425.3.1.lve.1.el7h 4.18.0-425.3.1.lve.2.el7h 4.18.0-425.3.1.lve.3.el7h 4.18.0-425.10.1.lve.el7h 4.18.0-425.13.1.lve.el7h 4.18.0-425.19.2.lve.el7h 4.18.0-477.10.1.lve.1.el7h 4.18.0-477.13.1.lve.el7h 4.18.0-477.15.1.lve.1.el7h 4.18.0-477.21.1.lve.el7h 4.18.0-477.13.1.lve.1.el7h 4.18.0-477.27.1.lve.el7h 4.18.0-477.15.1.lve.2.el7h 4.18.0-477.21.1.lve.1.el7h 4.18.0-513.5.1.lve.el7h 4.18.0-477.27.2.lve.el7h 4.18.0-513.9.1.lve.el7h 4.18.0-513.11.1.lve.el7h 4.18.0-513.18.1.lve.el7h 4.18.0-513.11.1.lve.1.el7h 4.18.0-513.18.1.lve.2.el7h 4.18.0-513.18.1.lve.1.el7h 4.18.0-513.24.1.lve.el7h 4.18.0-553.lve.el7h 4.18.0-513.24.1.lve.1.el7h 4.18.0-513.24.1.lve.2.el7h 4.18.0-553.5.1.lve.el7h 4.18.0-553.8.1.lve.el7h 4.18.0-553.5.1.lve.1.el7h 4.18.0-553.16.1.lve.el7h 4.18.0-553.16.1.lve.1.el7h
Released
AlmaLinux 8
4.18.0-240.el8 show all hide all
4.18.0-240.15.1.el8_3 4.18.0-240.22.1.el8_3 4.18.0-305.el8 4.18.0-305.3.1.el8_4 4.18.0-305.7.1.el8_4 4.18.0-305.10.2.el8_4 4.18.0-305.12.1.el8_4 4.18.0-305.17.1.el8_4 4.18.0-305.19.1.el8_4 4.18.0-305.25.1.el8_4 4.18.0-348.el8 4.18.0-348.2.1.el8_5 4.18.0-348.7.1.el8_5 4.18.0-348.12.2.el8_5 4.18.0-348.20.1.el8_5 4.18.0-348.23.1.el8_5 4.18.0-372.9.1.el8 4.18.0-372.13.1.el8_6 4.18.0-372.19.1.el8_6 4.18.0-372.16.1.el8_6 4.18.0-372.26.1.el8_6 4.18.0-372.32.1.el8_6 4.18.0-425.3.1.el8 4.18.0-425.10.1.el8_7 4.18.0-425.13.1.el8_7 4.18.0-425.19.2.el8_7 4.18.0-477.10.1.el8_8 4.18.0-477.13.1.el8_8 4.18.0-477.15.1.el8_8 4.18.0-477.21.1.el8_8 4.18.0-477.27.1.el8_8 4.18.0-513.5.1.el8_9 4.18.0-513.9.1.el8_9 4.18.0-477.27.2.el8_8 4.18.0-513.11.1.el8_9 4.18.0-513.18.1.el8_9 4.18.0-513.24.1.el8_9 4.18.0-513.18.2.el8_9 4.18.0-553.el8_10 4.18.0-553.5.1.el8_10 4.18.0-553.8.1.el8_10 4.18.0-553.16.1.el8_10
Released
Rocky Linux 8
4.18.0-305.3.1.el8_4 show all hide all
4.18.0-305.7.1.el8_4 4.18.0-305.10.2.el8_4 4.18.0-305.12.1.el8_4 4.18.0-305.17.1.el8_4 4.18.0-305.19.1.el8_4 4.18.0-305.25.1.el8_4 4.18.0-348.2.1.el8_5 4.18.0-348.12.2.el8_5 4.18.0-348.20.1.el8_5 4.18.0-348.7.1.el8_5 4.18.0-348.23.1.el8_5 4.18.0-372.9.1.el8 4.18.0-372.13.1.el8_6 4.18.0-372.19.1.el8_6 4.18.0-372.16.1.el8_6 4.18.0-372.16.1.el8_6.0.1 4.18.0-372.26.1.el8_6 4.18.0-372.32.1.el8_6 4.18.0-425.3.1.el8 4.18.0-425.10.1.el8_7 4.18.0-425.13.1.el8_7 4.18.0-425.19.2.el8_7 4.18.0-477.10.1.el8_8 4.18.0-477.13.1.el8_8 4.18.0-477.15.1.el8_8 4.18.0-477.27.1.el8_8 4.18.0-477.21.1.el8_8 4.18.0-513.5.1.el8_9 4.18.0-513.9.1.el8_9 4.18.0-513.11.1.el8_9 4.18.0-513.18.1.el8_9 4.18.0-513.11.1.el8_9.0.1 4.18.0-513.24.1.el8_9 4.18.0-553.el8_10 4.18.0-553.5.1.el8_10 4.18.0-553.8.1.el8_10 4.18.0-553.16.1.el8_10
Released
RHEL 9
5.14.0-70.17.1.el9_0 show all hide all
5.14.0-70.22.1.el9_0 5.14.0-70.5.1.el9_0 5.14.0-70.13.1.el9_0 5.14.0-70.26.1.el9_0 5.14.0-70.30.1.el9_0 5.14.0-162.6.1.el9_1 5.14.0-162.12.1.el9_1 5.14.0-162.18.1.el9_1 5.14.0-162.22.2.el9_1 5.14.0-162.23.1.el9_1 5.14.0-284.11.1.el9_2 5.14.0-284.18.1.el9_2 5.14.0-284.25.1.el9_2 5.14.0-284.30.1.el9_2 5.14.0-362.8.1.el9_3 5.14.0-362.13.1.el9_3 5.14.0-362.18.1.el9_3 5.14.0-362.24.1.el9_3 5.14.0-427.13.1.el9_4 5.14.0-427.16.1.el9_4 5.14.0-427.18.1.el9_4 5.14.0-427.20.1.el9_4 5.14.0-427.22.1.el9_4 5.14.0-427.24.1.el9_4 5.14.0-427.26.1.el9_4 5.14.0-427.28.1.el9_4 5.14.0-427.31.1.el9_4 5.14.0-427.33.1.el9_4 5.14.0-427.35.1.el9_4 5.14.0-427.37.1.el9_4 5.14.0-427.40.1.el9_4
Released
Oracle Linux 9
5.14.0-70.13.1.0.3.el9_0 show all hide all
5.14.0-70.17.1.0.1.el9_0 5.14.0-70.22.1.0.1.el9_0 5.14.0-70.26.1.0.1.el9_0 5.14.0-162.6.1.el9_1 5.14.0-284.11.1.el9_2 5.14.0-162.23.1.el9_1 5.14.0-162.22.2.el9_1 5.14.0-162.18.1.el9_1 5.14.0-162.12.1.el9_1 5.14.0-70.30.1.0.1.el9_0 5.14.0-284.18.1.el9_2 5.14.0-284.25.1.el9_2 5.14.0-284.25.1.0.1.el9_2 5.14.0-284.30.0.1.el9_2 5.14.0-284.30.1.el9_2 5.14.0-362.8.1.el9_3 5.14.0-362.13.0.1.el9_3 5.14.0-362.13.1.el9_3 5.14.0-362.18.0.1.el9_3 5.14.0-362.18.0.2.el9_3 5.14.0-362.18.1.el9_3 5.14.0-362.24.1.el9_3 5.14.0-362.24.1.0.1.el9_3 5.14.0-427.13.1.el9_4 5.14.0-427.16.1.el9_4 5.14.0-362.24.1.0.2.el9_3 5.14.0-427.18.1.el9_4 5.14.0-427.20.1.el9_4 5.14.0-427.22.1.el9_4 5.14.0-427.24.1.el9_4 5.14.0-427.26.1.el9_4 5.14.0-427.28.1.el9_4 5.14.0-427.31.1.el9_4 5.14.0-427.33.1.el9_4 5.14.0-427.35.1.el9_4 5.14.0-427.37.1.el9_4 5.14.0-427.40.1.el9_4
Released
Rocky Linux 9
5.14.0-162.6.1.el9_1 show all hide all
5.14.0-70.26.1.el9_0 5.14.0-70.30.1.el9_0 5.14.0-70.22.1.el9_0 5.14.0-162.6.1.el9_1.0.1 5.14.0-162.18.1.el9_1 5.14.0-162.12.1.el9_1.0.1 5.14.0-162.12.1.el9_1.0.2 5.14.0-162.22.2.el9_1 5.14.0-162.23.1.el9_1 5.14.0-284.30.1.el9_2 5.14.0-362.8.1.el9_3 5.14.0-362.13.1.el9_3 5.14.0-362.18.1.el9_3 5.14.0-362.24.1.el9_3 5.14.0-362.18.1.el9_3.0.1 5.14.0-427.16.1.el9_4 5.14.0-362.24.1.el9_3.0.1 5.14.0-427.18.1.el9_4 5.14.0-427.20.1.el9_4 5.14.0-427.24.1.el9_4 5.14.0-427.26.1.el9_4 5.14.0-427.28.1.el9_4 5.14.0-427.20.1.el9_4.0.1 5.14.0-427.22.1.el9_4 5.14.0-427.31.1.el9_4 5.14.0-427.33.1.el9_4 5.14.0-427.35.1.el9_4 5.14.0-427.37.1.el9_4 5.14.0-427.40.1.el9_4
Released
AlmaLinux 9
5.14.0-162.6.1.el9_1 show all hide all
5.14.0-70.26.1.el9_0 5.14.0-70.30.1.el9_0 5.14.0-70.17.1.el9_0 5.14.0-70.22.1.el9_0 5.14.0-162.12.1.el9_1 5.14.0-162.18.1.el9_1 5.14.0-162.22.2.el9_1 5.14.0-162.23.1.el9_1 5.14.0-284.11.1.el9_2 5.14.0-284.18.1.el9_2 5.14.0-70.13.1.el9_0 5.14.0-284.25.1.el9_2 5.14.0-284.30.1.el9_2 5.14.0-362.8.1.el9_3 5.14.0-362.13.1.el9_3 5.14.0-362.18.1.el9_3 5.14.0-362.24.1.el9_3 5.14.0-427.13.1.el9_4 5.14.0-427.16.1.el9_4 5.14.0-362.24.2.el9_3 5.14.0-427.18.1.el9_4 5.14.0-427.20.1.el9_4 5.14.0-427.24.1.el9_4 5.14.0-427.26.1.el9_4 5.14.0-427.28.1.el9_4 5.14.0-427.22.1.el9_4 5.14.0-427.31.1.el9_4 5.14.0-427.33.1.el9_4 5.14.0-427.35.1.el9_4 5.14.0-427.37.1.el9_4 5.14.0-427.40.1.el9_4
Released
RHEL8 EUS 8.6
4.18.0-372.51.1.el8_6 show all hide all
4.18.0-372.46.1.el8_6 4.18.0-372.41.1.el8_6 4.18.0-372.36.1.el8_6 4.18.0-372.52.1.el8_6 4.18.0-372.57.1.el8_6 4.18.0-372.64.1.el8_6 4.18.0-372.70.1.el8_6 4.18.0-372.75.1.el8_6 4.18.0-372.80.1.el8_6 4.18.0-372.87.1.el8_6 4.18.0-372.91.1.el8_6 4.18.0-372.93.1.el8_6 4.18.0-372.95.1.el8_6 4.18.0-372.98.1.el8_6 4.18.0-372.100.1.el8_6 4.18.0-372.102.1.el8_6 4.18.0-372.105.1.el8_6 4.18.0-372.107.1.el8_6 4.18.0-372.111.1.el8_6 4.18.0-372.118.1.el8_6 4.18.0-372.119.1.el8_6 4.18.0-372.113.1.el8_6 4.18.0-372.109.1.el8_6 4.18.0-372.115.1.el8_6 4.18.0-372.121.1.el8_6 4.18.0-372.123.1.el8_6 4.18.0-372.124.1.el8_6 4.18.0-372.125.1.el8_6 4.18.0-372.126.1.el8_6
Released
Ubuntu 24.04
Planned