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 16BF81F8724 for ; Wed, 16 Apr 2025 14:16:28 +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=1744812988; cv=none; b=iakxnpPIlxq3HPzHaPVaEsTGrZBpJQUyCC5lK/NY/Z3iDM6RRi5/k4O3aoEQL6CZgDcjNxyeoep9LQC7hJJtWYid1YI9+NSS48l1xR2nJTrz0mYi95K1ZSL6m99VYcVYxOyro1hEKERLc5HZC4snp9gMGxs4Qlq27+lTaGstFKw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744812988; c=relaxed/simple; bh=UG41UgIm1/HUgK0FDPodXPtdNmDL0sBE3nZS3soDGYQ=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=Gd3h0g4LpwfdFdGI3E8B3s/PRIDCvq7k0fUciaiWyf/6YfGI8CooAZidhPAUeYlpr7TDk6iPfhDAo6NOBIQ1sRxOR8vA9GQQ53ygDXdV89+1hBmPi+ToYCBcvDfrxoNRLe6f8Ans0QIzsnZWzKTtRZhEQj40TS7AAVBDp2C9044= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=B0suRlM9; 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="B0suRlM9" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 49010C4CEE2; Wed, 16 Apr 2025 14:16:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1744812988; bh=UG41UgIm1/HUgK0FDPodXPtdNmDL0sBE3nZS3soDGYQ=; h=From:To:Cc:Subject:Date:Reply-to:From; b=B0suRlM9wYGqH9Slnfak7D6Ra+8/zqaxurNxiNwT6c7+z65mV6JMHgUdUDM7RFz6Q WoM3OGER1ouZGNUIXF4f2GBfwbLuXvC0wHm8oFbcHiB021+Wk0ZJQIU+w2d3x3vvHQ O1VC1lKnUAcSZ/aQtcT3eScJUnVM1PXThDpJ9CzM= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-22082: iio: backend: make sure to NULL terminate stack buffer Date: Wed, 16 Apr 2025 16:12:53 +0200 Message-ID: <2025041614-CVE-2025-22082-dcb0@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=2410; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=UG41UgIm1/HUgK0FDPodXPtdNmDL0sBE3nZS3soDGYQ=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn/d+17yViS+JxtxwPOtMXcCpZlxgKSSv6TSp03qJ5de r93BrNTRywLgyATg6yYIsuXbTxH91ccUvQytD0NM4eVCWQIAxenAEykXZ1hwerKEt+PirxmkrEZ H07uLVsZ7hsYzjCHo299cdsRvddXmVOrY/yWcE2tu3QTAA== 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: iio: backend: make sure to NULL terminate stack buffer Make sure to NULL terminate the buffer in iio_backend_debugfs_write_reg() before passing it to sscanf(). It is a stack variable so we should not assume it will 0 initialized. The Linux kernel CVE team has assigned CVE-2025-22082 to this issue. Affected and fixed versions =========================== Issue introduced in 6.12 with commit cdf01e0809a4c6c7877ea52401c2a6679df7aed6 and fixed in 6.12.23 with commit df3892e5e861c43d5612728ed259634675b8a71f Issue introduced in 6.12 with commit cdf01e0809a4c6c7877ea52401c2a6679df7aed6 and fixed in 6.13.11 with commit 04271a4d2740f98bbe36f82cd3d74677a839d1eb Issue introduced in 6.12 with commit cdf01e0809a4c6c7877ea52401c2a6679df7aed6 and fixed in 6.14.2 with commit fd791c81f410ab1c554686a6f486dc7a176dfe35 Issue introduced in 6.12 with commit cdf01e0809a4c6c7877ea52401c2a6679df7aed6 and fixed in 6.15-rc1 with commit 035b4989211dc1c8626e186d655ae8ca5141bb73 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-22082 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/iio/industrialio-backend.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/df3892e5e861c43d5612728ed259634675b8a71f https://git.kernel.org/stable/c/04271a4d2740f98bbe36f82cd3d74677a839d1eb https://git.kernel.org/stable/c/fd791c81f410ab1c554686a6f486dc7a176dfe35 https://git.kernel.org/stable/c/035b4989211dc1c8626e186d655ae8ca5141bb73