CVE-2023-52735

bpf, sockmap: Don't let sock_map_{close,destroy,unhash} call itself

State
Published
Severity
9.1 Critical
Published
May 21, 2024
Updated
May 23, 2026
Reserved
May 21, 2024

Read the record on cve.org

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/

Scores

CVSSScoreVectorSource
3.19.1 CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:HCISA-ADP

Weaknesses

  • CWE-120 Buffer Copy without Checking Size of Input ('Classic Buffer Overflow')

Affected Products

ProductVersions
LinuxLinux
  • c5cc0d23c5414d23438c5024890e367cc5a0e645 to before f312367f5246e04df564d341044286e9e37a97baAffected
  • c5d2177a72a1659554922728fc407f59950aa929 to before 7499859881488da97589f3c79cc66fa75748ad49Affected
  • c5d2177a72a1659554922728fc407f59950aa929 to before 5b4a79ba65a1ab479903fff2e604865d229b70a9Affected
  • 0580e47c8895a4d61ee095f086cba1ded7ca5e7fAffected
  • 5.15.3 to before 5.15.95Affected
  • 5.14.19 to before 5.15Affected
LinuxLinux
  • 5.16Affected
  • before 5.16Not affected
  • 5.15.95 through 5.15.*Not affected
  • 6.1.13 through 6.1.*Not affected
  • 6.2 and laterNot affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.