| 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-2021-47057: crypto: sun8i-ss - Fix memory leak of object d when dma_iv fails to map |
| |
| Description |
| =========== |
| |
| In the Linux kernel, the following vulnerability has been resolved: |
| |
| crypto: sun8i-ss - Fix memory leak of object d when dma_iv fails to map |
| |
| In the case where the dma_iv mapping fails, the return error path leaks |
| the memory allocated to object d. Fix this by adding a new error return |
| label and jumping to this to ensure d is free'd before the return. |
| |
| Addresses-Coverity: ("Resource leak") |
| |
| The Linux kernel CVE team has assigned CVE-2021-47057 to this issue. |
| |
| |
| Affected and fixed versions |
| =========================== |
| |
| Issue introduced in 5.10 with commit ac2614d721dea2ff273af19c6c5d508d58a2bb3e and fixed in 5.10.37 with commit 617ec35ed51f731a593ae7274228ef2cfc9cb781 |
| Issue introduced in 5.10 with commit ac2614d721dea2ff273af19c6c5d508d58a2bb3e and fixed in 5.11.21 with commit e1f2d739849c3239df1ea3f97d40bade4b808410 |
| Issue introduced in 5.10 with commit ac2614d721dea2ff273af19c6c5d508d58a2bb3e and fixed in 5.12.4 with commit 6516cb852d704ff8d615de1f93cd443a99736c3d |
| Issue introduced in 5.10 with commit ac2614d721dea2ff273af19c6c5d508d58a2bb3e and fixed in 5.13 with commit 98b5ef3e97b16eaeeedb936f8bda3594ff84a70e |
| |
| 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-2021-47057 |
| 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/crypto/allwinner/sun8i-ss/sun8i-ss-prng.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/617ec35ed51f731a593ae7274228ef2cfc9cb781 |
| https://git.kernel.org/stable/c/e1f2d739849c3239df1ea3f97d40bade4b808410 |
| https://git.kernel.org/stable/c/6516cb852d704ff8d615de1f93cd443a99736c3d |
| https://git.kernel.org/stable/c/98b5ef3e97b16eaeeedb936f8bda3594ff84a70e |