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 558F4257455 for ; Fri, 2 May 2025 16:00:11 +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=1746201612; cv=none; b=p2taqVshqNnXJ7MwV/xsfuwUl9ewqG7BQ8QVLl1ji71Nz4GcD32jqlEbWWCR3W5jDV6aLe6c12JO2gA2B1xKEmb+ruhaCCLDDQCj3C9nNOIH3fQJWiWVCg11OPvon1B/iW46z5Bb+Yh4kVv2eSOa+/XzChXdL16OSDHcllA/Mcs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746201612; c=relaxed/simple; bh=lXxvoH9goH48WItRe5PTuiPa5B4nT1fESAsndbt4cKk=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=FHuGXtisdeqmSPwbakYPh+u5sff0ZQYSRxJhtH7OQiblNThxvaR+oTKFq+fv9Rb7kKDAVht+Lsal7YqheHoWTmfZZpnMJBldP+NcLz0rfrh/Y7g09FrfLNfpWeprgSf4UnJlNsKeA1Ng7i9bn0pxDJLnfxFF5C1I9EktPXVLGA0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=R55Zok+f; 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="R55Zok+f" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6D630C4CEE4; Fri, 2 May 2025 16:00:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1746201611; bh=lXxvoH9goH48WItRe5PTuiPa5B4nT1fESAsndbt4cKk=; h=From:To:Cc:Subject:Date:Reply-to:From; b=R55Zok+f+3o7b++qiS3pNfxQq4FevJzAdiJDd15ToDCfBjfyV7XyKKT1XjTKD47XN 1TmzQjCkCp4ZH6pWeb+Ql/lwQWXis/NgTyc6B8hsQYFeeSKsFYLco7ZFNELyFT8KoZ 7Ak2Yy4+wWlE9He3BA1QddYs+OaCgnyZkAK/JI4o= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2023-53083: nfsd: don't replace page in rq_pages if it's a continuation of last page Date: Fri, 2 May 2025 17:55:48 +0200 Message-ID: <2025050217-CVE-2023-53083-5b4e@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=3177; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=fLlu2CkG+yGjPAYQHtXvYdOnQJRkrcDMMCPKPCaynNE=; b=owGbwMvMwCRo6H6F97bub03G02pJDBkir56GeIZHqx76OuHkKzFbi7RL/450NezKkJz393Of1 OHPpRotHbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjCRNFeGeZauml16XFw7LEus XlzYrN/vq1PVzzBXrqTIOmj54wcugpKR20LkLJV39LQDAA== 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: nfsd: don't replace page in rq_pages if it's a continuation of last page The splice read calls nfsd_splice_actor to put the pages containing file data into the svc_rqst->rq_pages array. It's possible however to get a splice result that only has a partial page at the end, if (e.g.) the filesystem hands back a short read that doesn't cover the whole page. nfsd_splice_actor will plop the partial page into its rq_pages array and return. Then later, when nfsd_splice_actor is called again, the remainder of the page may end up being filled out. At this point, nfsd_splice_actor will put the page into the array _again_ corrupting the reply. If this is done enough times, rq_next_page will overrun the array and corrupt the trailing fields -- the rq_respages and rq_next_page pointers themselves. If we've already added the page to the array in the last pass, don't add it to the array a second time when dealing with a splice continuation. This was originally handled properly in nfsd_splice_actor, but commit 91e23b1c3982 ("NFSD: Clean up nfsd_splice_actor()") removed the check for it. The Linux kernel CVE team has assigned CVE-2023-53083 to this issue. Affected and fixed versions =========================== Issue introduced in 5.19 with commit 91e23b1c39820bfed642119ff6b6ef9f43cf09ce and fixed in 6.1.22 with commit 51ddb84baff6f09ad62b5999ece3ec172e4e3568 Issue introduced in 5.19 with commit 91e23b1c39820bfed642119ff6b6ef9f43cf09ce and fixed in 6.2.9 with commit 0101067f376eb7b9afd00279270f25d5111a091d Issue introduced in 5.19 with commit 91e23b1c39820bfed642119ff6b6ef9f43cf09ce and fixed in 6.3 with commit 27c934dd8832dd40fd34776f916dc201e18b319b 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-2023-53083 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/nfsd/vfs.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/8235cd619db6e67f1d7d26c55f1f3e4e575c947d https://git.kernel.org/stable/c/12eca509234acb6b666802edf77408bb70d7bfca https://git.kernel.org/stable/c/51ddb84baff6f09ad62b5999ece3ec172e4e3568 https://git.kernel.org/stable/c/0101067f376eb7b9afd00279270f25d5111a091d https://git.kernel.org/stable/c/27c934dd8832dd40fd34776f916dc201e18b319b