CVE-2024-38583 nilfs2: fix use-after-free of timer for log writer thread

High 7.8 Published Updated

A use-after-free vulnerability in the Linux kernel's nilfs2 file system allows attackers to potentially execute code or cause a denial of service.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Local or same network only
Victim action needed
Not needed
Fix
Available

What is CVE-2024-38583?

CVE-2024-38583 is a high-severity use after free vulnerability in Linux kernel, published on 19 Jun 2024. It can only be exploited from the same machine or local network, with no action from the victim.

Official description

In the Linux kernel, the following vulnerability has been resolved:

nilfs2: fix use-after-free of timer for log writer thread

Patch series "nilfs2: fix log writer related issues".

This bug fix series covers three nilfs2 log writer-related issues, including a timer use-after-free issue and potential deadlock issue on unmount, and a potential freeze issue in event synchronization found during their analysis. Details are described in each commit log.

This patch (of 3):

A use-after-free issue has been reported regarding the timer sc_timer on the nilfs_sc_info structure.

The problem is that even though it is used to wake up a sleeping log writer thread, sc_timer is not shut down until the nilfs_sc_info structure is about to be freed, and is used regardless of the thread's lifetime.

Fix this issue by limiting the use of sc_timer only while the log writer thread is alive.

Weakness: CWE-416

Which versions are affected by CVE-2024-38583?

It affects 1 product.

Products include Linux kernel.

How do I fix CVE-2024-38583?

Apply the vendor's patch.

Upgrade to the fixed version. These bugs are found with fuzzing and sanitisers and avoided by memory-safe languages. More about Use after free.

Is CVE-2024-38583 being exploited?

There is no known exploitation of CVE-2024-38583 in the wild and no public exploit code.

All Linux kernel vulnerabilities

Sources

Also known as BELL-CVE-2024-38583, DEBIAN-CVE-2024-38583, GHSA-frcg-wh52-w5v9, UBUNTU-CVE-2024-38583.

Is CVE-2024-38583 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free