CVE-2023-53307 rbd: avoid use-after-free in do_rbd_add() when rbd_dev_create() fails

High 7.8 Published Updated

A use-after-free vulnerability in the Linux kernel's rbd driver allows local attackers to potentially execute code or escalate privileges when device creation fails.

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-2023-53307?

CVE-2023-53307 is a high-severity use after free vulnerability in Linux kernel, published on 16 Sep 2025. 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:

rbd: avoid use-after-free in do_rbd_add() when rbd_dev_create() fails

If getting an ID or setting up a work queue in rbd_dev_create() fails, use-after-free on rbd_dev->rbd_client, rbd_dev->spec and rbd_dev->opts is triggered in do_rbd_add(). The root cause is that the ownership of these structures is transfered to rbd_dev prematurely and they all end up getting freed when rbd_dev_create() calls rbd_dev_free() prior to returning to do_rbd_add().

Found by Linux Verification Center (linuxtesting.org) with SVACE, an incomplete patch submitted by Natalia Petrova <[email protected]>.

Weakness: CWE-416

Which versions are affected by CVE-2023-53307?

It affects 1 product.

Products include Linux kernel.

How do I fix CVE-2023-53307?

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-2023-53307 being exploited?

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

All Linux kernel vulnerabilities

Sources

Also known as BELL-CVE-2023-53307, DEBIAN-CVE-2023-53307, GHSA-8r48-cm72-rr67, UBUNTU-CVE-2023-53307.

Is CVE-2023-53307 in your software?

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

Check your SBOMs for free