scsi: iscsi_tcp: Fix UAF during login when accessing the shost ipaddress
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ a79af8a64d395bd89de8695a5ea5e1a7f01f02a8 · < 61e43ebfd243bcbad11be26bd921723027b77441| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
scsi: iscsi_tcp: Fix UAF during login when accessing the shost ipaddress
If during iscsi_sw_tcp_session_create() iscsi_tcp_r2tpool_alloc() fails, userspace could be accessing the host's ipaddress attr. If we then free the session via iscsi_session_teardown() while userspace is still accessing the session we will hit a use after free bug.
Set the tcp_sw_host->session after we have completed session creation and can no longer fail.
From the CVE record · Linux
The Linux kernel's iscsi_tcp session-creation path has a use-after-free vulnerability. It can occur if iSCSI resource allocation fails while userspace is accessing the host's IP address attribute, leaving that access in progress when the session is freed.
Engineers running Linux kernels with the iscsi_tcp component should check their kernel version; affected versions were not specified.