CVE-2022-49312 Details
Description
In the Linux kernel, the following vulnerability has been resolved: staging: rtl8712: fix a potential memory leak in r871xu_drv_init() In r871xu_drv_init(), if r8712_init_drv_sw() fails, then the memory allocated by r8712_alloc_io_queue() in r8712_usb_dvobj_init() is not properly released as there is no action will be performed by r8712_usb_dvobj_deinit(). To properly release it, we should call r8712_free_io_queue() in r8712_usb_dvobj_deinit(). Besides, in r871xu_dev_remove(), r8712_usb_dvobj_deinit() will be called by r871x_dev_unload() under condition `padapter->bup` and r8712_free_io_queue() is called by r8712_free_drv_sw(). However, r8712_usb_dvobj_deinit() does not rely on `padapter->bup` and calling r8712_free_io_queue() in r8712_free_drv_sw() is negative for better understading the code. So I move r8712_usb_dvobj_deinit() into r871xu_dev_remove(), and remove r8712_free_io_queue() from r8712_free_drv_sw().
A memory leak vulnerability has been identified in the Linux kernel's staging RTL8712 driver. The issue arises in the 'r871xu_drv_init()' function, where the 'r8712_init_drv_sw()' failure prevents proper release of memory allocated by 'r8712_alloc_io_queue()'. This memory leak occurs because 'r8712_usb_dvobj_deinit()' does not execute under these failure conditions. The vulnerability can be exploited by causing 'r8712_init_drv_sw()' to fail, leading to an unaddressed memory allocation. The problem is exacerbated because 'r8712_usb_dvobj_deinit()' is not called in a way that accounts for the driver's initialization state, leaving allocated resources unreleased.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed Oct 1, 2025References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://git.kernel.org/stable/c/205e039fead72e87ad2838f5e649a4c4834f648b | kernel.org | Patch |
| https://git.kernel.org/stable/c/5a89a92efc342dd7c44b6056da87debc598f9c73 | kernel.org | Patch |
| https://git.kernel.org/stable/c/7288ff561de650d4139fab80e9cb0da9b5b32434 | kernel.org | Patch |
| https://git.kernel.org/stable/c/8eb42d6d10f8fe509117859defddf9e72b4fa4d0 | kernel.org | Patch |
| https://git.kernel.org/stable/c/a2882b8baad068d21c99fb2ab5a85a2bdbd5b834 | kernel.org | Patch |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-401 | Missing Release of Memory after Effective Lifetime | [email protected] |
| CWE-401 | Missing Release of Memory after Effective Lifetime | CISA-ADP |
Affected Products
| Product | Versions |
|---|---|
| linux linux kernel | < 5.10.122 >= 5.11, < 5.15.47 >= 5.16, < 5.17.15 >= 5.18, < 5.18.4 |
CPE
Remediation
| |
Change History
5 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | kernel.org |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| Oct 1, 2025 | CVE Modified | CISA-ADP |
| Mar 17, 2025 | Initial Analysis | [email protected] |
| Feb 26, 2025 | New CVE Received | kernel.org |