| From bippy-5f407fcff5a0 Mon Sep 17 00:00:00 2001 |
| From: Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
| To: <linux-cve-announce@vger.kernel.org> |
| Reply-to: <cve@kernel.org>, <linux-kernel@vger.kernel.org> |
| Subject: CVE-2022-49389: usb: usbip: fix a refcount leak in stub_probe() |
| |
| Description |
| =========== |
| |
| In the Linux kernel, the following vulnerability has been resolved: |
| |
| usb: usbip: fix a refcount leak in stub_probe() |
| |
| usb_get_dev() is called in stub_device_alloc(). When stub_probe() fails |
| after that, usb_put_dev() needs to be called to release the reference. |
| |
| Fix this by moving usb_put_dev() to sdev_free error path handling. |
| |
| Find this by code review. |
| |
| The Linux kernel CVE team has assigned CVE-2022-49389 to this issue. |
| |
| |
| Affected and fixed versions |
| =========================== |
| |
| Issue introduced in 3.19 with commit 3ff67445750a84de67faaf52c6e1895cb09f2c56 and fixed in 4.9.318 with commit 6bafee2f18af5e5ac125e42960bc65496d0e56a0 |
| Issue introduced in 3.19 with commit 3ff67445750a84de67faaf52c6e1895cb09f2c56 and fixed in 4.14.283 with commit f20d2d3b3364ce6525c050a8b6b4c54c8c19674d |
| Issue introduced in 3.19 with commit 3ff67445750a84de67faaf52c6e1895cb09f2c56 and fixed in 4.19.247 with commit 247d3809e45a34d9e1a3a2bb7012e31ed8b46031 |
| Issue introduced in 3.19 with commit 3ff67445750a84de67faaf52c6e1895cb09f2c56 and fixed in 5.4.198 with commit 2f0ae93ec33c8456cdfbf7876b80403a6318ebce |
| Issue introduced in 3.19 with commit 3ff67445750a84de67faaf52c6e1895cb09f2c56 and fixed in 5.10.122 with commit bcbb795a9e78180d74c6ab21518da87e803dfdce |
| Issue introduced in 3.19 with commit 3ff67445750a84de67faaf52c6e1895cb09f2c56 and fixed in 5.15.47 with commit 51422046be504515eb5a591adf0f424b62f46804 |
| Issue introduced in 3.19 with commit 3ff67445750a84de67faaf52c6e1895cb09f2c56 and fixed in 5.17.15 with commit 8afb048800919d0ab10c57983940eba956339f21 |
| Issue introduced in 3.19 with commit 3ff67445750a84de67faaf52c6e1895cb09f2c56 and fixed in 5.18.4 with commit 11c65408bd0ba1d9cd1307caa38169292de9cdfb |
| Issue introduced in 3.19 with commit 3ff67445750a84de67faaf52c6e1895cb09f2c56 and fixed in 5.19 with commit 9ec4cbf1cc55d126759051acfe328d489c5d6e60 |
| Issue introduced in 3.16.58 with commit 77e7f91231bf63e3c64eb59a2aaf5754eaea2e69 |
| Issue introduced in 3.18.110 with commit d0f35e23dafa0185f979d0c70463caa658062264 |
| |
| Please see https://www.kernel.org for a full list of currently supported |
| kernel versions by the kernel community. |
| |
| Unaffected versions might change over time as fixes are backported to |
| older supported kernel versions. The official CVE entry at |
| https://cve.org/CVERecord/?id=CVE-2022-49389 |
| will be updated if fixes are backported, please check that for the most |
| up to date information about this issue. |
| |
| |
| Affected files |
| ============== |
| |
| The file(s) affected by this issue are: |
| drivers/usb/usbip/stub_dev.c |
| |
| |
| Mitigation |
| ========== |
| |
| The Linux kernel CVE team recommends that you update to the latest |
| stable kernel version for this, and many other bugfixes. Individual |
| changes are never tested alone, but rather are part of a larger kernel |
| release. Cherry-picking individual commits is not recommended or |
| supported by the Linux kernel community at all. If however, updating to |
| the latest release is impossible, the individual changes to resolve this |
| issue can be found at these commits: |
| https://git.kernel.org/stable/c/6bafee2f18af5e5ac125e42960bc65496d0e56a0 |
| https://git.kernel.org/stable/c/f20d2d3b3364ce6525c050a8b6b4c54c8c19674d |
| https://git.kernel.org/stable/c/247d3809e45a34d9e1a3a2bb7012e31ed8b46031 |
| https://git.kernel.org/stable/c/2f0ae93ec33c8456cdfbf7876b80403a6318ebce |
| https://git.kernel.org/stable/c/bcbb795a9e78180d74c6ab21518da87e803dfdce |
| https://git.kernel.org/stable/c/51422046be504515eb5a591adf0f424b62f46804 |
| https://git.kernel.org/stable/c/8afb048800919d0ab10c57983940eba956339f21 |
| https://git.kernel.org/stable/c/11c65408bd0ba1d9cd1307caa38169292de9cdfb |
| https://git.kernel.org/stable/c/9ec4cbf1cc55d126759051acfe328d489c5d6e60 |