Skip to main content
← All vulnerabilities
CVE-2024-40909

bpf: Fix a potential use-after-free in bpf_link_free()

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 6.6.35, 6.9
None on Exploit-DB, Metasploit or GitHub
  • Exploitation: none
  • Automatable: no
  • Technical impact: partial

Summary

In the Linux kernel, the following vulnerability has been resolved: bpf: Fix a potential use-after-free in bpf_link_free() After commit 1a80dbcb2dba, bpf_link can be freed by link->ops->dealloc_deferred, but the code still tests and uses link->ops->dealloc afterward, which leads to a use-after-free as reported by syzbot. Actually, one of them should be sufficient, so just call one of them instead of both. Also add a WARN_ON() in case of any problematic implementation.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: none · Automatable: no · Technical impact: partial

  3. Record last updated

Affected versions

  • Linux Linux

    From 6.6.26 · fixed in 6.6.35; From 6.8.5 · fixed in 6.9

  • Linux Linux

    6.9

References 3

git.kernel.org