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

Published Jul 12, 2024
·
Updated

In the Linux kernel, the following vulnerability has been resolved:

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

After commit 1a80dbcb2dba, bpflink can be freed by link->ops->deallocdeferred, 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 WARNON() in case of any problematic implementation.

Affected Software

5 affected componentsFixes available
Linux Linux kernel>=6.6.26<6.6.35
Linux Linux kernel>=6.9<6.9.6
Linux Linux kernel=6.10-rc1
Linux Linux kernel=6.10-rc2
debian/linux
5.10.223-15.10.234-16.1.129-16.1.135-16.12.25-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 5.10.223-1Fixed in 5.10.234-1Fixed in 6.1.129-1Fixed in 6.1.135-1Fixed in 6.12.25-1
  2. Upgrade

    Upgrade Linux kernel (bpf) to a version that resolves this vulnerability.

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

Event History

Jul 12, 2024
CVE Published
via MITRE·12:20 PM
Data Sourced
via MITRE·12:20 PM
DescriptionSeverity
Data Sourced
via NVD·01:15 PM
RemedyDescriptionSeverityWeaknessAffected Software
Nov 30, 2024
Data Sourced
via Ubuntu·04:44 PM
RemedyDescriptionSeverityAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2024-40909?

CVE-2024-40909 has a moderate severity rating due to the potential for use-after-free vulnerabilities in the Linux kernel.

2

How do I fix CVE-2024-40909?

To remediate CVE-2024-40909, update the Linux kernel to a version that includes the fix, specifically above version 6.6.35 or 6.9.6.

3

Which versions of the Linux kernel are affected by CVE-2024-40909?

CVE-2024-40909 affects Linux kernel versions between 6.6.26 and 6.6.35, and versions around 6.9.0 to 6.9.6, including 6.10-rc1 and 6.10-rc2.

4

Is CVE-2024-40909 being actively exploited?

There is no current public information indicating that CVE-2024-40909 is actively being exploited.

5

Where can I find more information about CVE-2024-40909?

For detailed information on CVE-2024-40909, refer to the Linux kernel changelogs and security advisory documentation.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203