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 4B499142E7E for ; Tue, 21 May 2024 15:25:35 +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=1716305135; cv=none; b=eqwowYQGu5T8Mfpm9zzT2jOi7eY0TPPeWsuEQAImWy7zRJuQ1bnqEdC9ymLKDOEhhxBXOl5rZEWBlWxP8+kXcVQjIl1zT0YghTkOrzfhACiCzbk66YbLcQLoK84ds1tZG3xyBZ/wAaZJAMHi7lWWnGKWSU8kUoYNFvXMpgn3uN8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716305135; c=relaxed/simple; bh=a21MRBrwUz60aQSc+NwxtHgVZXS+d/lDmktERsYjUC0=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=lvYWMLIcZAGq9MRv6td3XN2282ROW8jUsRg4K4bLVK2ECX9jnObxXmJBaO3k5x10hZWgdBbzdlTaCDdmllyO1PqLNQHeELhmoVGQcYn/I5AEyI9KT6pe34wdH0bIu8BFAr4lkyIZW1OKZlu5N2LYB81BQAIVE/qI/h9wXvy9ENY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=dzq3YNcx; 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="dzq3YNcx" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C6656C2BD11; Tue, 21 May 2024 15:25:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1716305135; bh=a21MRBrwUz60aQSc+NwxtHgVZXS+d/lDmktERsYjUC0=; h=From:To:Cc:Subject:Date:Reply-to:From; b=dzq3YNcxvyKBB0LHEqq3dtobMixW3cBA4bo50TR9RB8VbkuwkgrJL57CWaiCOEysH 5AhwYi6nV5CqFO2tkbYHmfFDfbLV0ENVv5ZPOTt59SE7rL0VKZf7wDhxghWEVC9/h1 Zhs7JgNi62IBNhvRa/xD9ceM/cekWSYbXcc/bLdQ= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2023-52735: bpf, sockmap: Don't let sock_map_{close,destroy,unhash} call itself Date: Tue, 21 May 2024 17:23:12 +0200 Message-ID: <2024052100-CVE-2023-52735-4df1@gregkh> X-Mailer: git-send-email 2.45.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=1931; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=a21MRBrwUz60aQSc+NwxtHgVZXS+d/lDmktERsYjUC0=; b=owGbwMvMwCRo6H6F97bub03G02pJDGk+e0KKCjbbec4653r8cHuYn3L97EPBipH+is9iD57Me Gm1//aLjlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZhIsiPDPL0N085qG2R/Xhf9 0nWbuPWkFD0HZ4YF3cIHWa+FV5+w+21wYUtEvNC7JIPpAA== 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: bpf, sockmap: Don't let sock_map_{close,destroy,unhash} call itself sock_map proto callbacks should never call themselves by design. Protect against bugs like [1] and break out of the recursive loop to avoid a stack overflow in favor of a resource leak. [1] https://lore.kernel.org/all/00000000000073b14905ef2e7401@google.com/ The Linux kernel CVE team has assigned CVE-2023-52735 to this issue. Affected and fixed versions =========================== Fixed in 5.15.95 with commit f312367f5246 Fixed in 6.1.13 with commit 749985988148 Fixed in 6.2 with commit 5b4a79ba65a1 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-52735 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/core/sock_map.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/f312367f5246e04df564d341044286e9e37a97ba https://git.kernel.org/stable/c/7499859881488da97589f3c79cc66fa75748ad49 https://git.kernel.org/stable/c/5b4a79ba65a1ab479903fff2e604865d229b70a9