CVE-2024-46735

Source
https://cve.org/CVERecord?id=CVE-2024-46735
Import Source
https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2024-46735.json
JSON Data
https://api.test.osv.dev/v1/vulns/CVE-2024-46735
Downstream
Related
Published
2024-09-18T07:11:57.279Z
Modified
2026-03-20T12:39:07.433221Z
Summary
ublk_drv: fix NULL pointer dereference in ublk_ctrl_start_recovery()
Details

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

ublkdrv: fix NULL pointer dereference in ublkctrlstartrecovery()

When two UBLKCMDSTARTUSERRECOVERY commands are submitted, the first one sets 'ubq->ubqdaemon' to NULL, and the second one triggers WARN in ublkqueue_reinit() and subsequently a NULL pointer dereference issue.

Fix it by adding the check in ublkctrlstartrecovery() and return immediately in case of zero 'ub->nrqueues_ready'.

BUG: kernel NULL pointer dereference, address: 0000000000000028 RIP: 0010:ublkctrlstart_recovery.constprop.0+0x82/0x180 Call Trace: <TASK> ? __die+0x20/0x70 ? pagefaultoops+0x75/0x170 ? excpagefault+0x64/0x140 ? asmexcpagefault+0x22/0x30 ? ublkctrlstartrecovery.constprop.0+0x82/0x180 ublkctrluringcmd+0x4f7/0x6c0 ? picknexttaskidle+0x26/0x40 iouringcmd+0x9a/0x1b0 ioissuesqe+0x193/0x3f0 iowqsubmitwork+0x9b/0x390 ioworkerhandlework+0x165/0x360 iowqworker+0xcb/0x2f0 ? finishtaskswitch.isra.0+0x203/0x290 ? finishtaskswitch.isra.0+0x203/0x290 ? __pfxiowq_worker+0x10/0x10 retfromfork+0x2d/0x50 ? __pfxiowqworker+0x10/0x10 retfromforkasm+0x1a/0x30 </TASK>

Database specific
{
    "cna_assigner": "Linux",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/46xxx/CVE-2024-46735.json"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
c732a852b419fa057b53657e2daaf9433940391c
Fixed
ca249435893dda766f3845c15ca77ca5672022d8
Fixed
136a29d8112df4ea0a57f9602ddf3579e04089dc
Fixed
7c890ef60bf417d3fe5c6f7a9f6cef0e1d77f74f
Fixed
e58f5142f88320a5b1449f96a146f2f24615c5c7

Database specific

source
"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2024-46735.json"