CVE-2022-50840

Not scored yetLast modified Jun 17, 2026

Description

In the Linux kernel, the following vulnerability has been resolved:

scsi: snic: Fix possible UAF in snic_tgt_create()

Smatch reports a warning as follows:

drivers/scsi/snic/snic_disc.c:307 snic_tgt_create() warn: '&tgt->list' not removed from list

If device_add() fails in snic_tgt_create(), tgt will be freed, but tgt->list will not be removed from snic->disc.tgt_list, then list traversal may cause UAF.

Remove from snic->disc.tgt_list before free().

Metrics

No CVSS score has been published yet.

Affected software

VendorProductVersions
LinuxLinux>= c8806b6c9e824f47726f2a9b7fbbe7ebf19306fa, < f9d8b8ba0f1a16cde0b1fc9e80466df76b6db8ff; >= c8806b6c9e824f47726f2a9b7fbbe7ebf19306fa, < 3772319e40527e6a5f2ec1d729e01f271d818f5c; >= c8806b6c9e824f47726f2a9b7fbbe7ebf19306fa, < 3007f96ca20c848d0b1b052df6d2cb5ae5586e78; >= c8806b6c9e824f47726f2a9b7fbbe7ebf19306fa, < 6866154c23fba40888ad6d554cccd4bf2edb755e; >= c8806b6c9e824f47726f2a9b7fbbe7ebf19306fa, < ad27f74e901fc48729733c88818e6b96c813057d; >= c8806b6c9e824f47726f2a9b7fbbe7ebf19306fa, < 1895e908b3ae66a5312fd1b2cdda2da82993dca7; >= c8806b6c9e824f47726f2a9b7fbbe7ebf19306fa, < c7f0f8dab1ae5def57c1a8a9cafd6fabe1dc27cc; >= c8806b6c9e824f47726f2a9b7fbbe7ebf19306fa, < 4141cd9e8b3379aea52a85d2c35f6eaf26d14e86; >= c8806b6c9e824f47726f2a9b7fbbe7ebf19306fa, < e118df492320176af94deec000ae034cc92be754
LinuxLinux4.2

References

Timeline

Published
Dec 30, 2025
Last modified
Jun 17, 2026
NVD status
Deferred

Related CVEs from 2022

CVE-2022-508417.8In the Linux kernel, the following vulnerability has been resolved: fs/ntfs3: Add overflow check for attribute size The offset addition coCVE-2022-50842In the Linux kernel, the following vulnerability has been resolved: drm/virtio: Check whether transferred 2D BO is shmem Transferred 2D BOCVE-2022-50843In the Linux kernel, the following vulnerability has been resolved: dm clone: Fix UAF in clone_dtr() Dm_clone also has the same UAF probleCVE-2022-50844In the Linux kernel, the following vulnerability has been resolved: drm/amdgpu: Fix type of second parameter in odn_edit_dpm_table() callbaCVE-2022-50845In the Linux kernel, the following vulnerability has been resolved: ext4: fix inode leak in ext4_xattr_inode_create() on an error path TheCVE-2022-50846In the Linux kernel, the following vulnerability has been resolved: mmc: via-sdmmc: fix return value check of mmc_add_host() mmc_add_host(CVE-2022-50847In the Linux kernel, the following vulnerability has been resolved: drm/bridge: it6505: Initialize AUX channel in it6505_i2c_probe During CVE-2022-50848In the Linux kernel, the following vulnerability has been resolved: drivers: dio: fix possible memory leak in dio_init() If device_registeCVE-2022-50849In the Linux kernel, the following vulnerability has been resolved: pstore: Avoid kcore oops by vmap()ing with VM_IOREMAP An oops can be iCVE-2022-50850In the Linux kernel, the following vulnerability has been resolved: scsi: ipr: Fix WARNING in ipr_init() ipr_init() will not call unregistCVE-2022-50851In the Linux kernel, the following vulnerability has been resolved: vhost_vdpa: fix the crash in unmap a large memory While testing in vIOCVE-2022-50852In the Linux kernel, the following vulnerability has been resolved: wifi: mt76: mt7921: fix use after free in mt7921_acpi_read() Don't der