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 C3E2F2441AD for ; Mon, 10 Feb 2025 15:59:01 +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=1739203141; cv=none; b=Z62lk9xg/OD+OkW1hzIgfNUYf8nuW61RHk2SDu1rr4iPa89Abz4ZFCGhoeOMnI6qK7PtZoIjJ696eY66ybYID9oAh5EEh4ZeZPBZaruaJoYjOpG4wdrb7v2Dwc3ecr/3Ubn6b9ghUKf6IlIXxU/8OWMiMJlAou3coTa5ukT2lio= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1739203141; c=relaxed/simple; bh=J04I3VwJphcduvA9QIdQB+OfF3hXRFyTTk34kXk1bGI=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=Zs7/8YwFQ2Pm1IrMdkPCSyR62HCo7QejOgIezzNMILlO3cuhWeWiBFcm0KWHAHoB3kX7ojbNBFbs2f11yLMKLB7Y9rp/NHuhOrhG0A5D9phJgSG+xTckKdsGZZcRLmMCBvrrWUUJ9DlqePn3nYaxQPIpX3EkOHFcdQ1tK4JDaJM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=i38YozFZ; 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="i38YozFZ" Received: by smtp.kernel.org (Postfix) with ESMTPSA id B0E58C4CEE7; Mon, 10 Feb 2025 15:59:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1739203141; bh=J04I3VwJphcduvA9QIdQB+OfF3hXRFyTTk34kXk1bGI=; h=From:To:Cc:Subject:Date:Reply-to:From; b=i38YozFZrY/m/sxIDY0BzdHX2znOQplYmu8B10S0LC36/FVExn/lcrYSbCDvb70Qi vzL2WcQu0HLMzkhQfBQ2PSJUW0aTTv7eNGOxw/PVjzEsovcQl/8SnjbkxGJuDyXP+C OGiQw0BbLBF/gHd5VhZjCZfmMaeCrM33gf9jnVfU= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-21686: io_uring/rsrc: require cloned buffers to share accounting contexts Date: Mon, 10 Feb 2025 16:58:54 +0100 Message-ID: <2025021054-CVE-2025-21686-d416@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=2458; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=J04I3VwJphcduvA9QIdQB+OfF3hXRFyTTk34kXk1bGI=; b=owGbwMvMwCRo6H6F97bub03G02pJDOmrlOwmJZTeeqvkaRyW8X3FkZKVfu+lZVrEi/Q3cPP8d TNanKTVEcvCIMjEICumyPJlG8/R/RWHFL0MbU/DzGFlAhnCwMUpABM5pcswP62Ow+ibV2+P6e/0 39LP1NLXtZZ9ZZhfLThHo+FIGWflGruWnrnHMlkevHABAA== 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: io_uring/rsrc: require cloned buffers to share accounting contexts When IORING_REGISTER_CLONE_BUFFERS is used to clone buffers from uring instance A to uring instance B, where A and B use different MMs for accounting, the accounting can go wrong: If uring instance A is closed before uring instance B, the pinned memory counters for uring instance B will be decremented, even though the pinned memory was originally accounted through uring instance A; so the MM of uring instance B can end up with negative locked memory. The Linux kernel CVE team has assigned CVE-2025-21686 to this issue. Affected and fixed versions =========================== Issue introduced in 6.12 with commit 7cc2a6eadcd7a5aa36ac63e6659f5c6138c7f4d2 and fixed in 6.12.12 with commit efd96fbe23fa87de39116f632401f67b93be21ab Issue introduced in 6.12 with commit 7cc2a6eadcd7a5aa36ac63e6659f5c6138c7f4d2 and fixed in 6.13.1 with commit cafc60ae35f82ebf156b3245f979ca61cbb8e42c Issue introduced in 6.12 with commit 7cc2a6eadcd7a5aa36ac63e6659f5c6138c7f4d2 and fixed in 6.14-rc1 with commit 19d340a2988d4f3e673cded9dde405d727d7e248 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-21686 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: io_uring/rsrc.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/efd96fbe23fa87de39116f632401f67b93be21ab https://git.kernel.org/stable/c/cafc60ae35f82ebf156b3245f979ca61cbb8e42c https://git.kernel.org/stable/c/19d340a2988d4f3e673cded9dde405d727d7e248