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 1268C1FCC59 for ; Mon, 21 Oct 2024 19:41:34 +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=1729539694; cv=none; b=jhZEXaIUIDGgxuAvi6uuEtSC89GPKIdX6+Ib2ruvLhZyKR05exbHchZSqT50TEKB2+dudZiTryS6zF4T6G8/yaRMifbcgGkWvlMTSpQxDz8LYRJnE3yJDTpBtT8PfpOg2H2w4s6ItYPzt1iz8+YrOa2AuV5jGhCh1rQJq/aGfbk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729539694; c=relaxed/simple; bh=p0IbfhArQuw3bZiP9MI5LEpdaWzcInv8Bn0ZbUZwPA8=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=fIpFyBn0YHU/3pKxBhM1oJcHhqmFfL9tEC1wjBRI+owqXgEcvByzi27feZ2RNe+ApA+IyT56MCYqsFNl7TbivmelUERtiwRyjuHWeBFB9P4rIGq26JiGRT9sImrkq0k3cMXhyhN/ITX4N2Sd4l2vH+arwgH3S9lTIguva33dlJA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=tfBlacLC; 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="tfBlacLC" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7D963C4CEC3; Mon, 21 Oct 2024 19:41:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1729539693; bh=p0IbfhArQuw3bZiP9MI5LEpdaWzcInv8Bn0ZbUZwPA8=; h=From:To:Cc:Subject:Date:Reply-to:From; b=tfBlacLCOiCQSPHqvZByWDxDSqp+uAHxxgy0Mp4REi+xaNSHrfzaHOUksukHwvwJ6 uJT46g8B9ssd9BPMi6vGvLy7yQv9LC1lqGH172hTQ4+d9PwPmVJs82PaPo0tsKevn/ sKg3Xk0aS6vESNpEa+JiK5+4nZPSfwkQyrCidwOY= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2024-50028: thermal: core: Reference count the zone in thermal_zone_get_by_id() Date: Mon, 21 Oct 2024 21:39:34 +0200 Message-ID: <2024102130-CVE-2024-50028-5655@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=2192; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=p0IbfhArQuw3bZiP9MI5LEpdaWzcInv8Bn0ZbUZwPA8=; b=owGbwMvMwCRo6H6F97bub03G02pJDOliaz+tK3xjrhH7n0P6a0DnO0Y5VkmhGLOIl63/s96oJ u702nutI5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACZyWIRhftH233kFh9wO5kxt eOJ7oVw28PDn5wxzeGKrFmqd9dYI8W78bP8q8Wzx7gNLAQ== 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: thermal: core: Reference count the zone in thermal_zone_get_by_id() There are places in the thermal netlink code where nothing prevents the thermal zone object from going away while being accessed after it has been returned by thermal_zone_get_by_id(). To address this, make thermal_zone_get_by_id() get a reference on the thermal zone device object to be returned with the help of get_device(), under thermal_list_lock, and adjust all of its callers to this change with the help of the cleanup.h infrastructure. The Linux kernel CVE team has assigned CVE-2024-50028 to this issue. Affected and fixed versions =========================== Issue introduced in 5.9 with commit 1ce50e7d408e and fixed in 6.11.4 with commit c95538b286ef Issue introduced in 5.9 with commit 1ce50e7d408e and fixed in 6.12-rc3 with commit a42a5839f400 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-50028 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/thermal/thermal_core.c drivers/thermal/thermal_core.h drivers/thermal/thermal_netlink.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/c95538b286efc6109c987e97a051bc7844ede802 https://git.kernel.org/stable/c/a42a5839f400e929c489bb1b58f54596c4535167