# CVE-2022-50827: scsi: lpfc: Fix memory leak in lpfc\_create\_port()

- Priority: **Insufficient evidence**
- Reason: No CVSS vector published; no exploitation reported by the 5 checked sources
- Next step: Check the vendor advisory
- Status: published
- Published: 2025-12-30 · Modified: 2026-05-11
- Aliases: UBUNTU-CVE-2022-50827, DEBIAN-CVE-2022-50827
- Record: https://cvemate.com/vulnerability/CVE-2022-50827 · JSON: https://cvemate.com/vulnerability/CVE-2022-50827/json

## Description

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

scsi: lpfc: Fix memory leak in lpfc_create_port()

Commit 5e633302ace1 ("scsi: lpfc: vmid: Add support for VMID in mailbox
command") introduced allocations for the VMID resources in
lpfc_create_port() after the call to scsi_host_alloc(). Upon failure on the
VMID allocations, the new code would branch to the 'out' label, which
returns NULL without unwinding anything, thus skipping the call to
scsi_host_put().

Fix the problem by creating a separate label 'out_free_vmid' to unwind the
VMID resources and make the 'out_put_shost' label call only
scsi_host_put(), as was done before the introduction of allocations for
VMID.
```

## Signals

- CVSS: none published
- EPSS: 0.252%, percentile 17.732%, as of 2026-12-05
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 0

## Affected (first 20 of 106)

- debian linux (Debian): \< 6.0.6-1
- ubuntu linux (Ubuntu): \< 5.15.0-60.66
- ubuntu linux-allwinner-5.19 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws (Ubuntu): \< 5.15.0-1030.34
- ubuntu linux-aws-5.0 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.11 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.13 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.15 (Ubuntu): \< 5.15.0-1030.34~20.04.1
- ubuntu linux-aws-5.19 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.3 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.8 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-6.2 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-6.5 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-azure (Ubuntu): All versions (No fix recorded) \| \< 5.15.0-1033.40
- ubuntu linux-azure-5.11 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-azure-5.13 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-azure-5.15 (Ubuntu): \< 5.15.0-1033.40~20.04.1
- ubuntu linux-azure-5.19 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-azure-5.3 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-azure-5.8 (Ubuntu): All versions (No fix recorded)

## References

- <https://git.kernel.org/stable/c/9749595feb33a1a2b848800192224ffeed5346b4>
- <https://git.kernel.org/stable/c/5ea1f195f51c2bb5915ccfb2b2885ca81ce9262b>
- <https://git.kernel.org/stable/c/dc8e483f684a24cc06e1d5fa958b54db58855093>
- <https://ubuntu.com/security/CVE-2022-50827>
- <https://www.cve.org/CVERecord?id=CVE-2022-50827>
- <https://git.kernel.org/linus/dc8e483f684a24cc06e1d5fa958b54db58855093>
- <https://security-tracker.debian.org/tracker/CVE-2022-50827>

---

Data as of 2026-12-06T04:48:39.748Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
