From mboxrd@z Thu Jan 1 00:00:00 1970 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 23FE51A238C for ; Wed, 26 Feb 2025 01:58:17 +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=1740535097; cv=none; b=itH17ELis9vwejTNyRmkVlwpgkBe5FxggYSRM7saJlSKO9u9Upusvn5QO2dw3NU8f5wykDdgL95dsaWFKK8AKwJHBtMlvjy2IYoO40m8kQpo1de2h1pBctldGpqOH9W7vqWRvxvrac95vpB5lvf9riuFHh9X/DzUFMDe+TsEhwo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740535097; c=relaxed/simple; bh=EzszHb+0Id50Y1Jw8CyGNuhIZ0x6epxfCjdrZx+gZpk=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=DuPiffraVBpG8J56XE66GvsEICJ3DjLGE3pr/GzujSU2SHGMjhZvNQXwVuWnvTHEsWQoJehHysyfyMyn30ffAxWYEghyMJnMWDd7nvWrp16Dr9HJ3pGdvaTHVaZShDu9CnhSBynYse13oRtJthKZ97BjohyIXkrsMPHmKmZLF/Q= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=M74B2kAE; 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="M74B2kAE" Received: by smtp.kernel.org (Postfix) with ESMTPSA id ED72AC4CEDD; Wed, 26 Feb 2025 01:58:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1740535097; bh=EzszHb+0Id50Y1Jw8CyGNuhIZ0x6epxfCjdrZx+gZpk=; h=From:To:Cc:Subject:Date:Reply-to:From; b=M74B2kAEWlTiuTVogiE6X3SwzikpPv/e0g0NYdsLPBWUpQ4E58+C1q8TpFJc1p8/o kRvx1BBfQHCD24UU7tyoHa3MHnhpMDkGUosxS0oB6VDMgfxidi4dHaCTPfjpXdSfwa 4k8B4evt+VkZhT7bP08GTbXNvr1/L/XCNx93cQcY= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-49103: NFSv4.2: fix reference count leaks in _nfs42_proc_copy_notify() Date: Wed, 26 Feb 2025 02:55:08 +0100 Message-ID: <2025022600-CVE-2022-49103-751e@gregkh> X-Mailer: git-send-email 2.48.1 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=2574; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=EzszHb+0Id50Y1Jw8CyGNuhIZ0x6epxfCjdrZx+gZpk=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn7SixCulxFDyltSH64eaaJ4CXewuL2t2WCJvzPzTtcH yVYm8/riGVhEGRikBVTZPmyjefo/opDil6Gtqdh5rAygQxh4OIUgInwPWCYn9jw7lD2vORiNX0X X6b0V5dMJzjPZ1jQ48t37V338tIZ2d5nZ++LiN5sZ5gEAA== 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: NFSv4.2: fix reference count leaks in _nfs42_proc_copy_notify() [You don't often get email from xiongx18@fudan.edu.cn. Learn why this is important at http://aka.ms/LearnAboutSenderIdentification.] The reference counting issue happens in two error paths in the function _nfs42_proc_copy_notify(). In both error paths, the function simply returns the error code and forgets to balance the refcount of object `ctx`, bumped by get_nfs_open_context() earlier, which may cause refcount leaks. Fix it by balancing refcount of the `ctx` object before the function returns in both error paths. The Linux kernel CVE team has assigned CVE-2022-49103 to this issue. Affected and fixed versions =========================== Fixed in 5.10.111 with commit 9b9feec97c1fc7dd9bb69f62c4905cddf1801599 Fixed in 5.15.34 with commit b37f482ba9f0e6382c188e3fccf6c4b2fdc938eb Fixed in 5.16.20 with commit fb73bf6305f4eb8f0cf9a61ee874d55f019d6dc4 Fixed in 5.17.3 with commit f46f632f9cfae4b2e3635fa58840a8ec584c42e3 Fixed in 5.18 with commit b7f114edd54326f730a754547e7cfb197b5bc132 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-49103 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: fs/nfs/nfs42proc.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/9b9feec97c1fc7dd9bb69f62c4905cddf1801599 https://git.kernel.org/stable/c/b37f482ba9f0e6382c188e3fccf6c4b2fdc938eb https://git.kernel.org/stable/c/fb73bf6305f4eb8f0cf9a61ee874d55f019d6dc4 https://git.kernel.org/stable/c/f46f632f9cfae4b2e3635fa58840a8ec584c42e3 https://git.kernel.org/stable/c/b7f114edd54326f730a754547e7cfb197b5bc132