net/9p: Fix a potential socket leak in p9_socket_open
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 6b18662e239a032f908b7f6e164bdf7e2e0a32c9 · < 8782b32ef867de7981bbe9e86ecb90e92e8780bd| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
net/9p: Fix a potential socket leak in p9_socket_open
Both p9_fd_create_tcp() and p9_fd_create_unix() will call p9_socket_open(). If the creation of p9_trans_fd fails, p9_fd_create_tcp() and p9_fd_create_unix() will return an error directly instead of releasing the cscoket, which will result in a socket leak.
This patch adds sock_release() to fix the leak issue.
From the CVE record · Linux
The Linux kernel’s net/9p code can leak a socket when p9_trans_fd creation fails during a TCP or Unix socket connection. The input does not establish whether an attacker can trigger this failure, or specify access or user-interaction requirements.
Teams running the Linux kernel should check whether their version includes the net/9p fix; affected versions are not specified.