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 9362B20B7F4 for ; Tue, 1 Apr 2025 15:41:56 +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=1743522116; cv=none; b=RpQBG0f6/vuh5d3JYuAWmA38zm6Hd45mi+/OS4ia9Pih2tskhmx+zxmV1eu6lsGTZropFfk4BQMso6i9PW43aZkrkpnmuDBF/LSNCNRqg1Z4v9KXNdN5DqPTSGFJp/UpzKBUqYJUF5JadUVT1WGRImzmpxO/IY+3Fx4zUdataZg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1743522116; c=relaxed/simple; bh=Id1gbiUfBMo6kmtsewkFdtWxhr4oUaTvrN9TQvJUkz8=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=tHR9lDVSF9ClyECAPZcmkuY68L7O6lbSgzaMaLMWMB7BzEC7wfXU4X4CBEMeQ7ZttisDqkc3va8hl2hpnBrRGLDIFuSW2PFhkxvMasZAIv/HzbkrSke9EHLxidNUSs+o2DOxr2sLqFwUMFDRA+wFuQ3GZT4b8D6Mro9kx06ZUsk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=e5DuxCYq; 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="e5DuxCYq" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C5A9DC4CEE5; Tue, 1 Apr 2025 15:41:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1743522116; bh=Id1gbiUfBMo6kmtsewkFdtWxhr4oUaTvrN9TQvJUkz8=; h=From:To:Cc:Subject:Date:Reply-to:From; b=e5DuxCYqe9NS7c6mLqJ+0FOnXhYPApwy968BQYEA5m3YTn2KQbC3fEzl62lH+n8P0 p+e3oc+ig9+C9xTz411L3AX2Ce5EqhJO1j3L4+yc37oqrBxshk55tkbqWDXmJyOFIx YllwWZ4J0tkZqUbjuRD42E6wmN/TjSj/NslFemr8= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-21929: HID: intel-ish-hid: Fix use-after-free issue in hid_ishtp_cl_remove() Date: Tue, 1 Apr 2025 16:39:53 +0100 Message-ID: <2025040133-CVE-2025-21929-bf29@gregkh> X-Mailer: git-send-email 2.49.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=3269; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=Id1gbiUfBMo6kmtsewkFdtWxhr4oUaTvrN9TQvJUkz8=; b=owGbwMvMwCRo6H6F97bub03G02pJDOlvOLZ6K9U3CJ//+YG/3G7RIoPZNYsXm612EvyRHOJe9 c9kn1pmRywLgyATg6yYIsuXbTxH91ccUvQytD0NM4eVCWQIAxenAExkvwDDPPPYuoxbf+4+9K9y OdXmf/ZodMWUZQwLlvzdt2zuibOVb51eyqnukLkWYKvXBQA= 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: HID: intel-ish-hid: Fix use-after-free issue in hid_ishtp_cl_remove() During the `rmmod` operation for the `intel_ishtp_hid` driver, a use-after-free issue can occur in the hid_ishtp_cl_remove() function. The function hid_ishtp_cl_deinit() is called before ishtp_hid_remove(), which can lead to accessing freed memory or resources during the removal process. Call Trace: ? ishtp_cl_send+0x168/0x220 [intel_ishtp] ? hid_output_report+0xe3/0x150 [hid] hid_ishtp_set_feature+0xb5/0x120 [intel_ishtp_hid] ishtp_hid_request+0x7b/0xb0 [intel_ishtp_hid] hid_hw_request+0x1f/0x40 [hid] sensor_hub_set_feature+0x11f/0x190 [hid_sensor_hub] _hid_sensor_power_state+0x147/0x1e0 [hid_sensor_trigger] hid_sensor_runtime_resume+0x22/0x30 [hid_sensor_trigger] sensor_hub_remove+0xa8/0xe0 [hid_sensor_hub] hid_device_remove+0x49/0xb0 [hid] hid_destroy_device+0x6f/0x90 [hid] ishtp_hid_remove+0x42/0x70 [intel_ishtp_hid] hid_ishtp_cl_remove+0x6b/0xb0 [intel_ishtp_hid] ishtp_cl_device_remove+0x4a/0x60 [intel_ishtp] ... Additionally, ishtp_hid_remove() is a HID level power off, which should occur before the ISHTP level disconnect. This patch resolves the issue by reordering the calls in hid_ishtp_cl_remove(). The function ishtp_hid_remove() is now called before hid_ishtp_cl_deinit(). The Linux kernel CVE team has assigned CVE-2025-21929 to this issue. Affected and fixed versions =========================== Issue introduced in 6.8 with commit f645a90e8ff732c48dd9f18815baef08c44ac8a0 and fixed in 6.12.19 with commit 9c677fe859a73f5dd3dd84c27f99e10d28047c73 Issue introduced in 6.8 with commit f645a90e8ff732c48dd9f18815baef08c44ac8a0 and fixed in 6.13.7 with commit e040f11fbca868c6d151e9f2c5730c476abfcf17 Issue introduced in 6.8 with commit f645a90e8ff732c48dd9f18815baef08c44ac8a0 and fixed in 6.14 with commit 823987841424289339fdb4ba90e6d2c3792836db 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-2025-21929 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/hid/intel-ish-hid/ishtp-hid-client.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/9c677fe859a73f5dd3dd84c27f99e10d28047c73 https://git.kernel.org/stable/c/e040f11fbca868c6d151e9f2c5730c476abfcf17 https://git.kernel.org/stable/c/823987841424289339fdb4ba90e6d2c3792836db