nvmet: avoid potential UAF in nvmet_req_complete()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ a07b4970f464f13640e28e16dad6cfa33647cc99 · < bcd535f07c58342302a2cd2bdd8894fe0872c8a9| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
nvmet: avoid potential UAF in nvmet_req_complete()
An nvme target ->queue_response() operation implementation may free the request passed as argument. Such implementation potentially could result in a use after free of the request pointer when percpu_ref_put() is called in nvmet_req_complete().
Avoid such problem by using a local variable to save the sq pointer before calling __nvmet_req_complete(), thus avoiding dereferencing the req pointer after that function call.
From the CVE record · Linux
The Linux kernel’s NVMe target can use a request pointer after it has been freed if a queue_response() implementation frees the request during completion. The input does not establish how an attacker could trigger this condition or whether network access, authentication, or user interaction is required.
Engineers running the Linux kernel with NVMe target functionality should check their installations; affected versions were not provided.