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 09B2C1FDE33 for ; Wed, 16 Apr 2025 14:17:21 +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=1744813041; cv=none; b=BuLgAZuZJc7K1rsZ/Koq/eKEod1qmNTT8XHG70szofyRcTZgB2ZaMKl/DErbW9UDFuzc/d4XE99XCGMuZwoXbsvjjWjUSmuS2q9wcIGHJogpniWWxwKvwuM5GS851Lj7LSe5MMUdjmFPuz2FcdzUEb85SwhJfNGKNbKiG1aI7XY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744813041; c=relaxed/simple; bh=ULa0VvakETzap+xy6srdZv8u3NmWBM31+xZvYWP1h94=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=WcMgKNETFAP1RAszemTFIorLez1CKK4iIuXflUuDQF+t8A/+8o8lb0I2MEI0WkujrTJUs3j7DhYFTAnUYf5SvChmCZJHkK/0nU1SybY6cY7d+1QxCaClNRuFdRjgnFBj6LYrpRE6d2CUY9VnsiMgs+SNrE+we5ii5vJuF2Qmdkc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=JPEmJ0da; 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="JPEmJ0da" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 80712C4CEE2; Wed, 16 Apr 2025 14:17:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1744813040; bh=ULa0VvakETzap+xy6srdZv8u3NmWBM31+xZvYWP1h94=; h=From:To:Cc:Subject:Date:Reply-to:From; b=JPEmJ0daiIt5PYIinoekwr6H8CRPkK0uEEoHLEtVvn6CTHX+uUk9MPcS+d7gX8WM4 +EDJZhrnlsElvA0cnLgGmNVG4h2Wnsc+jWBz32N/xm+W62LnqOwfnKNNNkFdEHkvFM XRhJebi3hXrj67t500Apc0xiUceCnJ2xUC8cBnKY= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-22097: drm/vkms: Fix use after free and double free on init error Date: Wed, 16 Apr 2025 16:13:08 +0200 Message-ID: <2025041619-CVE-2025-22097-d4f5@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=3182; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=ULa0VvakETzap+xy6srdZv8u3NmWBM31+xZvYWP1h94=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn/dx22TDDSfM1oYi7KX7Xz60X972zz6rw1Fr1ePSHzR lPzTZs1HbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjARNUmGBUd92ra+3uwn4abn yXJmxcvQZ4s2JTDMz9g3iUn/ZT93WYXQFD8+xowKSdPPAA== 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: drm/vkms: Fix use after free and double free on init error If the driver initialization fails, the vkms_exit() function might access an uninitialized or freed default_config pointer and it might double free it. Fix both possible errors by initializing default_config only when the driver initialization succeeded. The Linux kernel CVE team has assigned CVE-2025-22097 to this issue. Affected and fixed versions =========================== Issue introduced in 5.12 with commit 2df7af93fdadb9ba8226fe443fae15ecdefda2a6 and fixed in 5.15.180 with commit 49a69f67f53518bdd9b7eeebf019a2da6cc0e954 Issue introduced in 5.12 with commit 2df7af93fdadb9ba8226fe443fae15ecdefda2a6 and fixed in 6.1.134 with commit 79d138d137b80eeb0a83244d1cff29e64cf91067 Issue introduced in 5.12 with commit 2df7af93fdadb9ba8226fe443fae15ecdefda2a6 and fixed in 6.6.87 with commit 561fc0c5cf41f646f3e9e61784cbc0fc832fb936 Issue introduced in 5.12 with commit 2df7af93fdadb9ba8226fe443fae15ecdefda2a6 and fixed in 6.12.23 with commit d5eb8e347905ab17788a7903fa1d3d06747355f5 Issue introduced in 5.12 with commit 2df7af93fdadb9ba8226fe443fae15ecdefda2a6 and fixed in 6.13.11 with commit b8a18bb53e06d6d3c1fd03d12533d6e333ba8853 Issue introduced in 5.12 with commit 2df7af93fdadb9ba8226fe443fae15ecdefda2a6 and fixed in 6.14.2 with commit 1f68f1cf09d06061eb549726ff8339e064eddebd Issue introduced in 5.12 with commit 2df7af93fdadb9ba8226fe443fae15ecdefda2a6 and fixed in 6.15-rc1 with commit ed15511a773df86205bda66c37193569575ae828 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-22097 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/gpu/drm/vkms/vkms_drv.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/49a69f67f53518bdd9b7eeebf019a2da6cc0e954 https://git.kernel.org/stable/c/79d138d137b80eeb0a83244d1cff29e64cf91067 https://git.kernel.org/stable/c/561fc0c5cf41f646f3e9e61784cbc0fc832fb936 https://git.kernel.org/stable/c/d5eb8e347905ab17788a7903fa1d3d06747355f5 https://git.kernel.org/stable/c/b8a18bb53e06d6d3c1fd03d12533d6e333ba8853 https://git.kernel.org/stable/c/1f68f1cf09d06061eb549726ff8339e064eddebd https://git.kernel.org/stable/c/ed15511a773df86205bda66c37193569575ae828