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 0DA291B4233 for ; Wed, 26 Feb 2025 01:59:26 +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=1740535166; cv=none; b=lQBhc8KdvXaIikD/m+3sm0Nu5DwWYfKzU/GcuhfbnMctAfI3bIVkLHm2qLYKIwW0VRDsMm5mlk8XpEfQBNQWoCU6+q5Zl0HwA/j8nO/KhrfC0Ry0x0UCtZYMZZDzXoobC65p4YeXT4rDCxrtcPT4NAsbILxQWmcdZELWBYGYaaY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740535166; c=relaxed/simple; bh=qVcGa48q7BPCyyhdG/iPJ9o0umLi1KVuZf42xAKryFA=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=Y6be8rkUaKK2huoEqWOTqkYIXU2Gpl8V7aTFInezMrxn6k5m0ywwr/EUI4nGsYSu/+858zu9YC/MPCsgJhcROaLKLOC37r43H9qY8cSWUF7JGpwjM6LtKutrZaPoplUGATvt6mOv+15AyAfHgQ0GyrvxbNMIoLXpo2K/f0P0Jp0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=ZqKUmM1j; 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="ZqKUmM1j" Received: by smtp.kernel.org (Postfix) with ESMTPSA id D76F6C4CEDD; Wed, 26 Feb 2025 01:59:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1740535165; bh=qVcGa48q7BPCyyhdG/iPJ9o0umLi1KVuZf42xAKryFA=; h=From:To:Cc:Subject:Date:Reply-to:From; b=ZqKUmM1jKYWdgzmV6Oqg80Lf3TcxAwwa3RKQm+pabjmm5wiuMFv4la0aFDo17BPA2 wUrLhL4BMn/p3tsZA9J5wvB6hOhAjk4TkS7eWNZRiKpJar77qyiCLlhU+ZOkrzW791 RKCUYOIJAj10T+o33bBi8A4eptHLOp5cIGm62eQo= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-49199: RDMA/nldev: Prevent underflow in nldev_stat_set_counter_dynamic_doit() Date: Wed, 26 Feb 2025 02:56:44 +0100 Message-ID: <2025022617-CVE-2022-49199-54e5@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=2147; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=qVcGa48q7BPCyyhdG/iPJ9o0umLi1KVuZf42xAKryFA=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn7SjwNnm54f8T5/BU9+3ker6V55la3P7ynvd1f8Jfnl ONPPjsbdsSyMAgyMciKKbJ82cZzdH/FIUUvQ9vTMHNYmUCGMHBxCsBEDp9imCucvLxFbPLBhHXP zTxmTZhyRXmOvybDPNO7QjtFwhefkfn+NCRMnGn/mTopGQA= 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: RDMA/nldev: Prevent underflow in nldev_stat_set_counter_dynamic_doit() This code checks "index" for an upper bound but it does not check for negatives. Change the type to unsigned to prevent underflows. The Linux kernel CVE team has assigned CVE-2022-49199 to this issue. Affected and fixed versions =========================== Issue introduced in 5.16 with commit 3c3c1f1416392382faa0238e76a70d7810aab2ef and fixed in 5.16.19 with commit f6dd8669b8299a3a536cd92a7069152a7704da1d Issue introduced in 5.16 with commit 3c3c1f1416392382faa0238e76a70d7810aab2ef and fixed in 5.17.2 with commit 2a495ef04d5f42e6f00eb2bec1ee9075e3d5a771 Issue introduced in 5.16 with commit 3c3c1f1416392382faa0238e76a70d7810aab2ef and fixed in 5.18 with commit 87e0eacb176f9500c2063d140c0a1d7fa51ab8a5 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-49199 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/infiniband/core/nldev.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/f6dd8669b8299a3a536cd92a7069152a7704da1d https://git.kernel.org/stable/c/2a495ef04d5f42e6f00eb2bec1ee9075e3d5a771 https://git.kernel.org/stable/c/87e0eacb176f9500c2063d140c0a1d7fa51ab8a5