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 D09382868A4 for ; Wed, 18 Jun 2025 11:03:15 +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=1750244595; cv=none; b=DSKwfe0x5bC22VR3VDv8Ev9hKenrtLB2tuDb9rHa+YtbpkNBfxXnttC4SAh4nGsy9NEEfMmcsze1jnaL4iuzi8EwmJzuCnmdg3sqSfhVuPNqab0b6zlqRAqj8k2zlIX0ZBNU8KvIZfH7gzItq82FRYvl6OuawRNDA3PYSXsIa2s= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1750244595; c=relaxed/simple; bh=yCYhYV22aRQMHKr1CQVZEGybFhl3XmyJhm/Hv3FwWko=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=ok0t9+lGtWThj/xbdDpMN+ihQ3P07lRv9sI4NyIWswFfXJIl9q7/b4XGjFL3z4jQjT8l2OcZVVBs1NP2PrUEwzm7MubQt9yMywsMCzbwL1nCoFW6od54qSJ6VXQHGgAQu/Rl9zFrmtd+zgcyHo4FEBvi+UL5FKMJ3qN+6yQcap0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=Z+crMru+; 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="Z+crMru+" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 62FBDC4CEE7; Wed, 18 Jun 2025 11:03:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1750244595; bh=yCYhYV22aRQMHKr1CQVZEGybFhl3XmyJhm/Hv3FwWko=; h=From:To:Cc:Subject:Date:Reply-to:From; b=Z+crMru+YsXYvAdLSYKHm+v5ZQVgSx3SFUS572RyX00J95DSj3xAjum3KTDzB4ycy 6BvzUDk7626B3cbicRPczWMAM+b1g4ay+RJS3n5MPkNgZHMdCl9fQ5y03mBiSEtb6d +XfVONMBbakagcCNEZdiMLm+GkNlrfyrMDLMe4vc= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-49975: bpf: Don't redirect packets with invalid pkt_len Date: Wed, 18 Jun 2025 13:00:40 +0200 Message-ID: <2025061819-CVE-2022-49975-89e6@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=2448; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=Un1AHT7ot1PP3nlJ5Zb9rs3+fTru+bO19Xx6QucvpF0=; b=owGbwMvMwCRo6H6F97bub03G02pJDBlBc5wnHV2jGsJ3RnUTW26EZ1nBzX1T4pd99RY2fHYy8 4rH//W+HbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjCRf6UM8zPNJVOsWnwuTC3T P+0ZyqEy6cvk2QwLVuiWNjIaNT74M/WJXWzdwxtl6zvnAwA= 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: bpf: Don't redirect packets with invalid pkt_len Syzbot found an issue [1]: fq_codel_drop() try to drop a flow whitout any skbs, that is, the flow->head is null. The root cause, as the [2] says, is because that bpf_prog_test_run_skb() run a bpf prog which redirects empty skbs. So we should determine whether the length of the packet modified by bpf prog or others like bpf_prog_test is valid before forwarding it directly. The Linux kernel CVE team has assigned CVE-2022-49975 to this issue. Affected and fixed versions =========================== Fixed in 5.4.212 with commit 8b68e53d56697a59b5c53893b53f508bbdf272a0 Fixed in 5.10.141 with commit 6204bf78b2a903b96ba43afff6abc0b04d6e0462 Fixed in 5.15.65 with commit a75987714bd2d8e59840667a28e15c1fa5c47554 Fixed in 5.19.7 with commit 72f2dc8993f10262092745a88cb2dd0fef094f23 Fixed in 6.0 with commit fd1894224407c484f652ad456e1ce423e89bb3eb 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-49975 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: include/linux/skbuff.h net/bpf/test_run.c net/core/dev.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/8b68e53d56697a59b5c53893b53f508bbdf272a0 https://git.kernel.org/stable/c/6204bf78b2a903b96ba43afff6abc0b04d6e0462 https://git.kernel.org/stable/c/a75987714bd2d8e59840667a28e15c1fa5c47554 https://git.kernel.org/stable/c/72f2dc8993f10262092745a88cb2dd0fef094f23 https://git.kernel.org/stable/c/fd1894224407c484f652ad456e1ce423e89bb3eb