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 C74C829BD8C for ; Tue, 30 Dec 2025 12:14:43 +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=1767096883; cv=none; b=aPakgsgtK3uWBibwBMJ+wR8Of/p8HntVDLjhb4aEINGeeZQbBCH339xJHwzShyXl+Ps5CtWup9XxNkEqzqJLzXY6RhxNY/MYpnTJlrvwVGsROolMTU9jKx74mSfHKJUnJ3vwPN/tlz7g/mRoTT1WaYE/Y0VMXPsB9V+acCsxaHo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767096883; c=relaxed/simple; bh=8hn3dzkTwZH41CE0RqACM9llpQvbNzQssF7VvAG6b9c=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=PcIdJuoh9sKS293Fob42PAFjmPQyKkkLd3Y+z0i2B7FfBMWF/R+ZTt57U2LOTZmC0wdI0Zn61rvoLHcMpRUkLQSHiQPKO0NGOAf/jsUa6jRW7mdtPEMBsiy2c0bzpY3+phJ84xzSpqSg92hJRD6PZ17W5XvfG+TfdN0aAISwqs8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=tx1WTgiu; 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="tx1WTgiu" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 52AD9C4CEFB; Tue, 30 Dec 2025 12:14:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1767096883; bh=8hn3dzkTwZH41CE0RqACM9llpQvbNzQssF7VvAG6b9c=; h=From:To:Cc:Subject:Date:Reply-To:From; b=tx1WTgiuSdPepbHQqPzMz0kpewXS9+JBYDnCbQES9FVsOMqOQv/7YopSnnYVRX9Ac d+zVsldwg9od3s/2bxdbaziIAkhuG2ZTokJUszWAVUcp9Q4WAg5Cm6aLKvQSIe+LmT aSzuvEcUicZV6IdIifdhf5PnXVobFm8V1fyNo/aY= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-50837: net: dsa: tag_8021q: avoid leaking ctx on dsa_tag_8021q_register() error path Date: Tue, 30 Dec 2025 13:13:23 +0100 Message-ID: <2025123018-CVE-2022-50837-c470@gregkh> X-Mailer: git-send-email 2.52.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2422; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=INRItK9WUYN6emcbTY0mcC7tylnT7kP/giY85rDxxl8=; b=owGbwMvMwCRo6H6F97bub03G02pJDJnBB+/9nblpZ4YUL5O494zuyab92UxrbHwjJfZX/JTTt 1rTsSe8I5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACbCt4ZhQa9j4c8fy49vnuJv uYcz66XdmjMxixjmSj08dOpX02mlFW8bv8/h3XzqYZj9YQA= 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: net: dsa: tag_8021q: avoid leaking ctx on dsa_tag_8021q_register() error path If dsa_tag_8021q_setup() fails, for example due to the inability of the device to install a VLAN, the tag_8021q context of the switch will leak. Make sure it is freed on the error path. The Linux kernel CVE team has assigned CVE-2022-50837 to this issue. Affected and fixed versions =========================== Issue introduced in 5.15 with commit 328621f6131f667c5c328bb72d45442fd76efb81 and fixed in 5.15.86 with commit 09f30f394e832ed09859b6a80fdd20668a9104ff Issue introduced in 5.15 with commit 328621f6131f667c5c328bb72d45442fd76efb81 and fixed in 6.0.16 with commit 39691d51af99f80efb9e365f94b8e0c791fa1a2f Issue introduced in 5.15 with commit 328621f6131f667c5c328bb72d45442fd76efb81 and fixed in 6.1.2 with commit 14ed46a13aba42a6ddd85de6f6274090df3586a5 Issue introduced in 5.15 with commit 328621f6131f667c5c328bb72d45442fd76efb81 and fixed in 6.2 with commit e095493091e850d5292ad01d8fbf5cde1d89ac53 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-50837 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: net/dsa/tag_8021q.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/09f30f394e832ed09859b6a80fdd20668a9104ff https://git.kernel.org/stable/c/39691d51af99f80efb9e365f94b8e0c791fa1a2f https://git.kernel.org/stable/c/14ed46a13aba42a6ddd85de6f6274090df3586a5 https://git.kernel.org/stable/c/e095493091e850d5292ad01d8fbf5cde1d89ac53