Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 90FA03A1AB for ; Fri, 17 May 2024 13:41:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715953314; cv=none; b=V+YMa3uGXAKRdF3wt7ya6CfYQ28CEDc7TKRTkXURiRpigx+nNhz+wXwIqvvW8HYgfxgnompUAcWZzZsRTxNuzLH7jg3oM+/Nv6X6ZobA6QjLJ4cXBfpgNpU09NcNFOeyZ3tzEEgWDBD9jiZ7jCJJqyrVqSqqYYfr4MQv99JTtwY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715953314; c=relaxed/simple; bh=EvzGrD46FnpB4XH319dtbdakcSsl7OIIDDUNurg9Cag=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=RVyB0K5HNFIP4piaOlBYFPSA4IGu8nlfwwjTyCoIrxCcIRIiSPhBZwR3mjrJ2fhEW7blvFNTigWzC0JjjbMauDAt+YT5dEZET6Me39u6byuHP8FNEbNwODguyCMjTl2D6JHSqhW4aZS5UdoHxMCNfsGv+4wzrZ5ULd0bpX0ATo0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=aIuRFtdx; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="aIuRFtdx" Received: by smtp.kernel.org (Postfix) with ESMTPSA id AFB86C2BD10; Fri, 17 May 2024 13:41:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1715953314; bh=EvzGrD46FnpB4XH319dtbdakcSsl7OIIDDUNurg9Cag=; h=From:To:Cc:Subject:Date:Reply-to:From; b=aIuRFtdxx+FyEE1jpBBuCK7FLrrvCLx/Acv/rC2T3kD4rjTix8+bCjmAzEcelzb+o IbdyZDV5m8vjgjTtXl3WjK/fBVog1PIopxgyd1ffs73QwWM5KO2DTkeTzCBHBaOyW5 lvXaDld3/ANvSqEbw73Q/qlHsMVxwHnYDdBR2ze4= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2023-52663: ASoC: SOF: amd: Fix memory leak in amd_sof_acp_probe() Date: Fri, 17 May 2024 15:41:41 +0200 Message-ID: <2024051740-CVE-2023-52663-1045@gregkh> X-Mailer: git-send-email 2.45.1 Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Reply-to: , X-Developer-Signature: v=1; a=openpgp-sha256; l=2300; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=EvzGrD46FnpB4XH319dtbdakcSsl7OIIDDUNurg9Cag=; b=owGbwMvMwCRo6H6F97bub03G02pJDGnucVMqzhrsdWZrTtO3jFuk0htZY//62Z9THQk6S/Zsi Np1+8a0jlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZhIOCfDgrMPIncp/jFt0c52 Pu230DjqTKfoIoaZjDYhN4MPb++eZRaa4NbBy3TH320OAA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit Description =========== In the Linux kernel, the following vulnerability has been resolved: ASoC: SOF: amd: Fix memory leak in amd_sof_acp_probe() Driver uses kasprintf() to initialize fw_{code,data}_bin members of struct acp_dev_data, but kfree() is never called to deallocate the memory, which results in a memory leak. Fix the issue by switching to devm_kasprintf(). Additionally, ensure the allocation was successful by checking the pointer validity. The Linux kernel CVE team has assigned CVE-2023-52663 to this issue. Affected and fixed versions =========================== Issue introduced in 6.6 with commit f7da88003c53 and fixed in 6.6.23 with commit 88028c45d587 Issue introduced in 6.6 with commit f7da88003c53 and fixed in 6.7.11 with commit be4760799c6a Issue introduced in 6.6 with commit f7da88003c53 and fixed in 6.8.2 with commit 7296152e5885 Issue introduced in 6.6 with commit f7da88003c53 and fixed in 6.9 with commit 222be59e5eed 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-2023-52663 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: sound/soc/sof/amd/acp.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/88028c45d5871dfc449b2b0a27abf6428453a5ec https://git.kernel.org/stable/c/be4760799c6a7c01184467287f0de41e0dd255f8 https://git.kernel.org/stable/c/7296152e58858f928db448826eb7ba5ae611297b https://git.kernel.org/stable/c/222be59e5eed1554119294edc743ee548c2371d0