bpf, sockmap: Don't let sock_map_{close,destroy,unhash} call itself
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
bpf, sockmap: Don't let sock_map_{close,destroy,unhash} call itself
sock_map proto callbacks should never call themselves by design. Protect against bugs like [1] and break out of the recursive loop to avoid a stack overflow in favor of a resource leak.
[1] https://lore.kernel.org/all/00000000000073b14905ef2e7401@google.com/
From the CVE record · Linux
The Linux kernel’s BPF sockmap callbacks can recursively call themselves, causing a stack overflow. The input does not specify how an attacker could trigger this, whether access or authentication is required, or whether user interaction is needed.
Anyone running the Linux kernel should check whether their version is affected; affected versions are not specified.