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 438543090D9 for ; Thu, 18 Sep 2025 13:34:52 +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=1758202493; cv=none; b=dbdOMF8MsE/hYppWVNflCOBp/odiEWIDAKEaA517kA3U8PLCju6eUCQkteo6yr+DEkdQTlRePu1JRtJAmDtF0f/Qds/+z9PmxgY3ObgLUKY0n8MXkk9DEn9WJHWAgjSPc4mp/FArIySJoU/pyKGM6+mrDJDswGHURCgkFLIxbJM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1758202493; c=relaxed/simple; bh=GcN2Kpt4n/RChKM1eEUoS7m18f9TnOLs29jpvX741/0=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=dMM36r9ZSnYgcJYt618BZdMB43DWtzQ1ndn+w4b/FCu//PVLg4/8XAXQe1Z5Vthaurab4cn77FOTijQQzhiY6Ka8cMxT/9cc4VoGfJKaUOaiQEcdhqkBBnw3y+KQqLKmAqbeicrb9cpktEbDYcY3FmoC0CyaYWcK5LaIwH62ODU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=VjeWcZ1V; 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="VjeWcZ1V" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 631EAC4CEEB; Thu, 18 Sep 2025 13:34:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1758202492; bh=GcN2Kpt4n/RChKM1eEUoS7m18f9TnOLs29jpvX741/0=; h=From:To:Cc:Subject:Date:Reply-to:From; b=VjeWcZ1VEIs1XOgC+ZPngtHRrpyStCa7WTKRbw3l/IZr90kqgjFZ/i3jgEW7q0Qxm B9u3WBdqbm6bbQTzXHJ1P3VazPCDiuC+5nLp7TZEbFgBH5z8soHHNqjKvKxWvJoq/W lWdKhuqJpRcWYL1Y2wwdBuk1wHQ8sxgYJXCHHqbc= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-50395: integrity: Fix memory leakage in keyring allocation error path Date: Thu, 18 Sep 2025 15:34:09 +0200 Message-ID: <2025091854-CVE-2022-50395-344c@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=2823; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=tlFTbJ+2Es/LK686ZOP8Bw7xxu9asuo7E1BcBFfhkKU=; b=owGbwMvMwCRo6H6F97bub03G02pJDBlnuJySmupjHm59vPqm9l5R10dFd80TePVqt4fXztO5d ym74+6LjlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZjI/PcMc+U1Gtk2yaezv9Vd mdxqOacrtzYrmGG++/eFcbO3V2Usz91/cB2H5mRv7hh1AA== 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: integrity: Fix memory leakage in keyring allocation error path Key restriction is allocated in integrity_init_keyring(). However, if keyring allocation failed, it is not freed, causing memory leaks. The Linux kernel CVE team has assigned CVE-2022-50395 to this issue. Affected and fixed versions =========================== Issue introduced in 4.12 with commit 2b6aa412ff23a02ac777ad307249c60a839cfd25 and fixed in 5.4.229 with commit 9b7c44885a07c5ee7f9bf3aa3c9c72fb110c8d22 Issue introduced in 4.12 with commit 2b6aa412ff23a02ac777ad307249c60a839cfd25 and fixed in 5.10.163 with commit 3bd737289c26be3cee4b9afaf61ef784a2af9d6e Issue introduced in 4.12 with commit 2b6aa412ff23a02ac777ad307249c60a839cfd25 and fixed in 5.15.86 with commit 29d6c69ba4b96a1de0376e44e5f8b38b13ec8803 Issue introduced in 4.12 with commit 2b6aa412ff23a02ac777ad307249c60a839cfd25 and fixed in 6.0.16 with commit 57e49ad12f8f5df0c48e1710c54b147a05a10c32 Issue introduced in 4.12 with commit 2b6aa412ff23a02ac777ad307249c60a839cfd25 and fixed in 6.1.2 with commit c591c48842f08d30ec6b8416757831985ed9a315 Issue introduced in 4.12 with commit 2b6aa412ff23a02ac777ad307249c60a839cfd25 and fixed in 6.2 with commit 39419ef7af0916cc3620ecf1ed42d29659109bf3 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-2022-50395 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: security/integrity/digsig.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/9b7c44885a07c5ee7f9bf3aa3c9c72fb110c8d22 https://git.kernel.org/stable/c/3bd737289c26be3cee4b9afaf61ef784a2af9d6e https://git.kernel.org/stable/c/29d6c69ba4b96a1de0376e44e5f8b38b13ec8803 https://git.kernel.org/stable/c/57e49ad12f8f5df0c48e1710c54b147a05a10c32 https://git.kernel.org/stable/c/c591c48842f08d30ec6b8416757831985ed9a315 https://git.kernel.org/stable/c/39419ef7af0916cc3620ecf1ed42d29659109bf3