CVE-2026-139113: rnbd-srv: fix use-after-free on two CLOSE messages
Exploitation: None known · CVSS 9.8 Critical · Unauthenticated · Published 2026-11-30
Description
In the Linux kernel, the following vulnerability has been resolved: rnbd-srv: fix use-after-free on two CLOSE messages process_msg_close() looks the sess_dev up with a kref, drops it right away, and only then takes the session mutex for the teardown. A session has several connections handled by different workers, so two CLOSE messages for the same ID both finish the lookup before either one tears the sess_dev down, and the second one works on freed memory. Any host that can open a device on the server can do that. Take the mutex first and look the ID up with xa_load() under it. The second CLOSE then finds nothing.
Enclave's analysis
This is a use-after-free race in the Linux kernel's rnbd-srv driver, which serves block devices to peers over RDMA. An unauthenticated peer that can reach the RTRS listener opens a device to get its ID, then fires two CLOSE messages that race across connections so the second touches freed memory. Today that's confirmed to crash the server; turning it into code execution needs heap grooming nobody has demonstrated. Patch if you run RNBD storage — otherwise this driver likely isn't even loaded.
Fix
Upgrade Linux kernel rnbd-srv driver (CONFIG_BLK_DEV_RNBD server role) to 6.1.193 / 6.6.163 / 6.12.119 / 6.18.65 / 7.3.6 (depending on branch). No fixed version is listed for Linux; follow the vendor advisory.
Affected versions
| Product | Vulnerable | Fixed in |
|---|---|---|
| Linux | 2de6c8de192b9341ffa5e84afe1ce6196d4eef41 before c47d198faf301278927ae62802626d19c32332d5 | Not listed |
| Linux | 2de6c8de192b9341ffa5e84afe1ce6196d4eef41 before d8cb9e9ba95dce0c4731f3c6cf50632fd8540cad | Not listed |
| Linux | 2de6c8de192b9341ffa5e84afe1ce6196d4eef41 before 0368a1ebc080e42f5c1c2708c621deae05fdb629 | Not listed |
| Linux | 2de6c8de192b9341ffa5e84afe1ce6196d4eef41 before c366173339de0cfcc3cbcaccfbe726459f9f96d4 | Not listed |
| Linux | 2de6c8de192b9341ffa5e84afe1ce6196d4eef41 before ccae722c4bc716df8a4cdde462071d034f92f32d | Not listed |
| Linux | 2de6c8de192b9341ffa5e84afe1ce6196d4eef41 before 4912dab88baa5f7034dc9e38807804d470ae5438 | Not listed |
| Linux | 5.8 | Not listed |
| Linux kernel rnbd-srv driver (CONFIG_BLK_DEV_RNBD server role) | 5.8 up to branch-specific fixes: 6.1.x < 6.1.193, 6.6.x < 6.6.163, 6.12.x < 6.12.119, 6.18.x < 6.18.65, 7.x < 7.3.6 | 6.1.193 / 6.6.163 / 6.12.119 / 6.18.65 / 7.3.6 (depending on branch) |