rxrpc: serialize kernel accept preallocation with socket teardown
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 00e907127e6f86d0f9b122d9b4347a8aa09a8b61 · < 35a967ff8b24db09ee429c39c5b5e6571639997d| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
rxrpc: serialize kernel accept preallocation with socket teardown
rxrpc_kernel_charge_accept() reads rx->backlog without any socket/backlog synchronization and passes that raw pointer into rxrpc_service_prealloc_one(). A concurrent rxrpc_discard_prealloc() sets rx->backlog = NULL and frees the backlog rings, so a kernel preallocation worker can keep using a freed struct rxrpc_backlog while updating *_backlog_head/tail and array slots.
Serialize the state check and backlog lookup with the socket lock, and reject kernel preallocation once teardown has disabled listening or discarded the service backlog.
From the CVE record · Linux
The Linux kernel's rxrpc accept preallocation can use a freed backlog if it runs concurrently with socket teardown. This creates a potential use-after-free; the input does not specify how an attacker could trigger the race or whether authentication or user interaction is required.
Engineers running Linux kernels with rxrpc should check their versions; affected versions are not specified.