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 38C2227A44C for ; Thu, 4 Sep 2025 15:35: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=1757000141; cv=none; b=dUQu9/dpAbBopyMF9l68mJo5yhsroIvl3bKm1ePzzbhlsbD6wVCFWiNCKksTW3452tAig5LhrzIJl7kGGGcZ8WnODWUFGVpvgiH6oqD0h3O4iRClRh/U60kBdPLsY3yhUtoqkZIWcCf0HI2MPQocaCyFNsHpTCkJKAcXlkQMmx8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1757000141; c=relaxed/simple; bh=dRH0zIw8hKODT3QAfz+gZ1H5c1ykTNBwn6TN7AsBtfY=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=WTNuUB6FJYthvXjgxkVvZNQ0M/4RNDryRLHoF9A8Bgk+ePe1QfKTy75zomJojO0dmI1FpVVP0BrFjoZ4RsatuaTsl7HKE8+0wcbzJKMIrlq3p5DrFmS4myQCWAhwXmCbhgY/lw+OLHFDorEgCNtbB+8kZ6/o1DS56ONXVUKgvuU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=YqJT+kAe; 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="YqJT+kAe" Received: by smtp.kernel.org (Postfix) with ESMTPSA id ACB9CC4CEF0; Thu, 4 Sep 2025 15:35:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1757000141; bh=dRH0zIw8hKODT3QAfz+gZ1H5c1ykTNBwn6TN7AsBtfY=; h=From:To:Cc:Subject:Date:Reply-to:From; b=YqJT+kAeyh7pC9PgIsd62xODo1d4piQu4nkzaYMpOcNT/ddm/w0w92Wael+cfF/ZR e1Ypll/AyojdiRfYUvzhp7dOV5lxgrWtu9vcX0898b5eIUqs1KQ8WV+al0aWFTh1xa V10IlxYmZwDzJVYd5uk5vaBvCLxbqioK97B0C/WA= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-38702: fbdev: fix potential buffer overflow in do_register_framebuffer() Date: Thu, 4 Sep 2025 17:33:07 +0200 Message-ID: <2025090453-CVE-2025-38702-0b09@gregkh> X-Mailer: git-send-email 2.51.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=2509; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=E4REIqUQfEKNq9HZwlUzid9Oz2PPAqLd09Uaa4HbR4k=; b=owGbwMvMwCRo6H6F97bub03G02pJDBk7N6paT3PhvBtzXGHHrvus9ppFDh025jU7Px/+++YQj 0qb9ZnojlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZjIj1yGBeteHrS+n2k37dET D0GGuWs8vJ3N1zEsWLWPy3WBmvrfPiuX3TNlkt4tm/zlGwA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: fbdev: fix potential buffer overflow in do_register_framebuffer() The current implementation may lead to buffer overflow when: 1. Unregistration creates NULL gaps in registered_fb[] 2. All array slots become occupied despite num_registered_fb < FB_MAX 3. The registration loop exceeds array bounds Add boundary check to prevent registered_fb[FB_MAX] access. The Linux kernel CVE team has assigned CVE-2025-38702 to this issue. Affected and fixed versions =========================== Fixed in 6.1.149 with commit 5c3f5a25c62230b7965804ce7a2e9305c3ca3961 Fixed in 6.6.103 with commit cbe740de32bb0fb7a5213731ff5f26ea6718fca3 Fixed in 6.12.43 with commit 806f85bdd3a60187c21437fc51baace11f659f35 Fixed in 6.15.11 with commit 2828a433c7d7a05b6f27c8148502095101dd0b09 Fixed in 6.16.2 with commit 248b2aab9b2af5ecf89d9d7955a2ff20c4b4a399 Fixed in 6.17-rc1 with commit 523b84dc7ccea9c4d79126d6ed1cf9033cf83b05 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-38702 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/video/fbdev/core/fbmem.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/5c3f5a25c62230b7965804ce7a2e9305c3ca3961 https://git.kernel.org/stable/c/cbe740de32bb0fb7a5213731ff5f26ea6718fca3 https://git.kernel.org/stable/c/806f85bdd3a60187c21437fc51baace11f659f35 https://git.kernel.org/stable/c/2828a433c7d7a05b6f27c8148502095101dd0b09 https://git.kernel.org/stable/c/248b2aab9b2af5ecf89d9d7955a2ff20c4b4a399 https://git.kernel.org/stable/c/523b84dc7ccea9c4d79126d6ed1cf9033cf83b05