CVE-2022-49839: scsi: scsi_transport_sas: Fix error handling in sas_phy_add()
In the Linux kernel, the following vulnerability has been resolved:
scsi: scsi_transport_sas: Fix error handling in sas_phy_add()
If transport_add_device() fails in sas_phy_add(), the kernel will crash
trying to delete the device in transport_remove_device() called from
sas_remove_host().
Unable to handle kernel NULL pointer dereference at virtual address 0000000000000108
CPU: 61 PID: 42829 Comm: rmmod Kdump: loaded Tainted: G W 6.1.0-rc1+ #173
pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : device_del+0x54/0x3d0
lr : device_del+0x37c/0x3d0
Call trace:
device_del+0x54/0x3d0
attribute_container_class_device_del+0x28/0x38
transport_remove_classdev+0x6c/0x80
attribute_container_device_trigger+0x108/0x110
transport_remove_device+0x28/0x38
sas_phy_delete+0x30/0x60 [scsi_transport_sas]
do_sas_phy_delete+0x6c/0x80 [scsi_transport_sas]
device_for_each_child+0x68/0xb0
sas_remove_children+0x40/0x50 [scsi_transport_sas]
sas_remove_host+0x20/0x38 [scsi_transport_sas]
hisi_sas_remove+0x40/0x68 [hisi_sas_main]
hisi_sas_v2_remove+0x20/0x30 [hisi_sas_v2_hw]
platform_remove+0x2c/0x60
Fix this by checking and handling return value of transport_add_device()
in sas_phy_add().
This is a Linux kernel denial-of-service issue in SAS SCSI transport handling. Under a failed device-add path, later cleanup can dereference a NULL pointer and crash the kernel. The business risk is service interruption on affected Linux systems, especially storage or server platforms using SAS hardware.
Executive priority
Treat as a moderate availability risk. Prioritize patching storage-heavy Linux servers and appliances where an unexpected kernel crash could interrupt business services. There is no supplied evidence of active exploitation, so emergency action is not supported by the provided sources.
Technical view
CVE-2022-49839 is a CWE-476 NULL pointer dereference in scsi_transport_sas sas_phy_add(). If transport_add_device() fails, sas_remove_host() can call transport_remove_device() and crash in device_del(). CVSS 3.1 is 5.5, local attack vector, low complexity, low privileges, no confidentiality or integrity impact, high availability impact.
Likely exposure
Exposure is likely limited to affected Linux kernel builds with SCSI SAS transport code, particularly systems using SAS storage controllers or related kernel modules. The source bundle lists Linux kernel versions including 2.6.14, 5.10.157, 5.15.80, 6.0.10, and 6.1 as affected.
Exploitation context
No source in the bundle reports active exploitation, and KEV status is false. The provided evidence shows a kernel crash during removal after a failed device-add operation. The sources do not describe a public exploit, weaponized trigger, or remote attack path.
Researcher notes
The root issue is missing error handling for transport_add_device() failure in sas_phy_add(). The crash path involves sas_remove_host(), sas_phy_delete(), transport_remove_device(), and device_del(). Source evidence supports availability impact only; affected-version boundaries and distro backports require vendor-specific confirmation.
Mitigation direction
Apply vendor kernel updates containing the referenced stable fixes.
Prioritize servers or appliances using SAS storage controllers.
Check distribution advisories for backported kernel packages.
Schedule reboot or module reload windows required by kernel updates.
If patching is delayed, reduce unnecessary local access to affected systems.
Validation and detection
Inventory Linux kernel versions across SAS-capable systems.
Check whether scsi_transport_sas or SAS controller modules are loaded.
Map installed kernels against vendor fixed package versions.
Review crash logs for device_del or sas_phy_delete traces.
Confirm patched kernels include one of the referenced stable commits.
Based on public source material and reviewed before publication.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cwe · low confidence lookup
CWE-476: Exact CWE lookup
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.
CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.
CWE-476 · source CWE mapping
NULL Pointer Dereference
NULL Pointer Dereference represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.