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 6AAB725634 for ; Tue, 19 Nov 2024 01:33:41 +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=1731980021; cv=none; b=jnyv+JJ8fmpo2e1dTmcs091Z+iQAEoqGl/GwfTZ4Nl6xeEY8/ps+5i2toq5QjKNcP7BxvxjZaC9pLjr0BFZoe98yAdtYRb7o8xqthxxeJK5zSgQpKZABCvRiysByg3cdyDqfM1PWbS8/jLITtpwSZfjMNfgmJ6ZwWFi+vyct14w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1731980021; c=relaxed/simple; bh=o4QbOkSJq6JgA7fBZA03SDadEbWC+gSoiKMe/b3IxkI=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=kE8wEpkAVdnqDMBySYqHE7wm15oNVw5fwWV3dOVxJbrlExkWmymHGWaO7k2woJjuKNlNuSPJcMkDbWBVh6I8ngKUMLlmBnATz9fGrl9hhsxXjzYOGHiH12yV7gfxzPfLDDLfz3Etj0V3Gj5jP7NZCQ95IJi8xIQAxLEk31FPNio= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=AfPQ0Vtz; 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="AfPQ0Vtz" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E7BBDC4CECC; Tue, 19 Nov 2024 01:33:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1731980021; bh=o4QbOkSJq6JgA7fBZA03SDadEbWC+gSoiKMe/b3IxkI=; h=From:To:Cc:Subject:Date:Reply-to:From; b=AfPQ0VtznEoO9/8dn96zZ/Phu0a5G3xr1IVCRNmnplmSjPl7Y7ysbN/xjrjJWy2Xa D8qZutS22cshXkTOWzFjSPfLBH5ImN3vgz6aF/tsxGQ9TjP1i8ypMxYxQ1wR7Z6hPg uqaiY8H/EAbSNpthATS9NSrPCj5iFjSG4ISOWfBw= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2024-50269: usb: musb: sunxi: Fix accessing an released usb phy Date: Tue, 19 Nov 2024 02:32:24 +0100 Message-ID: <2024111926-CVE-2024-50269-830b@gregkh> X-Mailer: git-send-email 2.47.0 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=3540; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=o4QbOkSJq6JgA7fBZA03SDadEbWC+gSoiKMe/b3IxkI=; b=owGbwMvMwCRo6H6F97bub03G02pJDOnWr1Zb6qzVMY9sMuKZ3MHXdT7v5JO2I6tqp/3+2O4ce vGMkDx7RywLgyATg6yYIsuXbTxH91ccUvQytD0NM4eVCWQIAxenAEwkpJ1hvsf1L/ltNsWiT40X u539f/HPwUvnbzHMlbwycbLPn/yOjz7y0d7bfnmzrVG+DgA= 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: usb: musb: sunxi: Fix accessing an released usb phy Commit 6ed05c68cbca ("usb: musb: sunxi: Explicitly release USB PHY on exit") will cause that usb phy @glue->xceiv is accessed after released. 1) register platform driver @sunxi_musb_driver // get the usb phy @glue->xceiv sunxi_musb_probe() -> devm_usb_get_phy(). 2) register and unregister platform driver @musb_driver musb_probe() -> sunxi_musb_init() use the phy here //the phy is released here musb_remove() -> sunxi_musb_exit() -> devm_usb_put_phy() 3) register @musb_driver again musb_probe() -> sunxi_musb_init() use the phy here but the phy has been released at 2). ... Fixed by reverting the commit, namely, removing devm_usb_put_phy() from sunxi_musb_exit(). The Linux kernel CVE team has assigned CVE-2024-50269 to this issue. Affected and fixed versions =========================== Issue introduced in 4.14 with commit 6ed05c68cbca and fixed in 4.19.324 with commit 721ddad94559 Issue introduced in 4.14 with commit 6ed05c68cbca and fixed in 5.4.286 with commit 4aa77d5ea994 Issue introduced in 4.14 with commit 6ed05c68cbca and fixed in 5.10.230 with commit 6e2848d1c8c0 Issue introduced in 4.14 with commit 6ed05c68cbca and fixed in 5.15.172 with commit 63559ba8077c Issue introduced in 4.14 with commit 6ed05c68cbca and fixed in 6.1.117 with commit ccd811c304d2 Issue introduced in 4.14 with commit 6ed05c68cbca and fixed in 6.6.61 with commit 8a30da5aa960 Issue introduced in 4.14 with commit 6ed05c68cbca and fixed in 6.11.8 with commit b08baa75b989 Issue introduced in 4.14 with commit 6ed05c68cbca and fixed in 6.12 with commit 498dbd9aea20 Issue introduced in 4.4.95 with commit 583a4219841d Issue introduced in 4.9.59 with commit b4ecc15d6f5a Issue introduced in 4.13.10 with commit a2259ebaa933 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-2024-50269 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/musb/sunxi.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/721ddad945596220c123eb6f7126729fe277ee4f https://git.kernel.org/stable/c/4aa77d5ea9944468e16c3eed15e858fd5de44de1 https://git.kernel.org/stable/c/6e2848d1c8c0139161e69ac0a94133e90e9988e8 https://git.kernel.org/stable/c/63559ba8077cbadae1c92a65b73ea522bf377dd9 https://git.kernel.org/stable/c/ccd811c304d2ee56189bfbc49302cb3c44361893 https://git.kernel.org/stable/c/8a30da5aa9609663b3e05bcc91a916537f66a4cd https://git.kernel.org/stable/c/b08baa75b989cf779cbfa0969681f8ba2dc46569 https://git.kernel.org/stable/c/498dbd9aea205db9da674994b74c7bf8e18448bd