CVE-2024-57841: net: fix memory leak in tcp_conn_request()

Published Jan 15, 2025
·
Updated

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

net: fix memory leak in tcpconnrequest()

If inetcskreqskqueuehashadd() return false, tcpconnrequest() will return without free the dst memory, which allocated in afops->routereq.

Here is the kmemleak stack:

unreferenced object 0xffff8881198631c0 (size 240): comm "softirq", pid 0, jiffies 4299266571 (age 1802.392s) hex dump (first 32 bytes): 00 10 9b 03 81 88 ff ff 80 98 da bc ff ff ff ff ................ 81 55 18 bb ff ff ff ff 00 00 00 00 00 00 00 00 .U.............. backtrace: [<ffffffffb93e8d4c>] kmemcachealloc+0x60c/0xa80 [<ffffffffba11b4c5>] dstalloc+0x55/0x250 [<ffffffffba227bf6>] rtdstalloc+0x46/0x1d0 [<ffffffffba23050a>] mkrouteoutput+0x29a/0xa50 [<ffffffffba23456b>] iprouteoutputkeyhash+0x10b/0x240 [<ffffffffba2346bd>] iprouteoutputflow+0x1d/0x90 [<ffffffffba254855>] inetcskroutereq+0x2c5/0x500 [<ffffffffba26b331>] tcpconnrequest+0x691/0x12c0 [<ffffffffba27bd08>] tcprcvstateprocess+0x3c8/0x11b0 [<ffffffffba2965c6>] tcpv4dorcv+0x156/0x3b0 [<ffffffffba299c98>] tcpv4rcv+0x1cf8/0x1d80 [<ffffffffba239656>] ipprotocoldeliverrcu+0xf6/0x360 [<ffffffffba2399a6>] iplocaldeliverfinish+0xe6/0x1e0 [<ffffffffba239b8e>] iplocaldeliver+0xee/0x360 [<ffffffffba239ead>] iprcv+0xad/0x2f0 [<ffffffffba110943>] netifreceiveskbonecore+0x123/0x140

Call dstrelease() to free the dst memory when inetcskreqskqueuehashadd() return false in tcpconnrequest().

Other sources

This CVE was automatically created from a reference found in an email or other text. If you are reading this, then this CVE entry is probably erroneous, since this text should be replaced by the official CVE description automatically.

Launchpad

Affected Software

16 affected componentsFixes available
Linux Linux kernel
Linux Linux kernel>=5.15.162<5.15.176
Linux Linux kernel>=6.1.97<6.1.124
Linux Linux kernel>=6.6.37<6.6.70
Linux Linux kernel>=6.9.8<6.12.9
Linux Linux kernel=6.13-rc1
Linux Linux kernel=6.13-rc2
Linux Linux kernel=6.13-rc3
Linux Linux kernel=6.13-rc4
Linux Linux kernel=6.13-rc5
debian/linux
5.10.223-15.10.234-16.1.129-16.1.135-16.12.27-1
debian/linux-6.1
6.1.129-1~deb11u1
Microsoft azl3 kernel 6.6.64.2-9<6.6.76.1-1
6.6.76.1-1
Microsoft cbl2 kernel 5.15.173.1-2<5.15.176.3-1
5.15.176.3-1
Microsoft cbl2 kernel 5.15.176.3-1<5.15.176.3-1
5.15.176.3-1
Microsoft azl3 kernel 6.6.76.1-1<6.6.76.1-1
6.6.76.1-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.27-1
  2. Upgrade

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

    Fixed in 6.1.129-1~deb11u1
  3. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 6.6.76.1-1
  4. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 5.15.176.3-1

Event History

Jan 15, 2025
CVE Published
via MITRE·01:10 PM
Data Sourced
via MITRE·01:10 PM
Description
Data Sourced
via NVD·01:15 PM
RemedyDescriptionSeverityWeaknessAffected Software
Mar 8, 2025
Data Sourced
via Microsoft·08:00 AM
DescriptionSeverityWeakness
Data Sourced
via Microsoft·08:00 AM
Affected Software
Updated
via Microsoft·08:00 AM
Affected Software
Updated
via Microsoft·08:00 AM
SeverityAffected Software
Updated
via Microsoft·08:00 AM
Description
Mar 27, 2025
Data Sourced
via Launchpad·06:48 PM
Description
May 2, 2025
Data Sourced
via Ubuntu·06:56 PM
RemedyDescriptionSeverityAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2024-57841?

The severity of CVE-2024-57841 is typically assessed as moderate due to its potential for causing a memory leak in the Linux kernel.

2

How do I fix CVE-2024-57841?

To fix CVE-2024-57841, it is recommended to apply the patches provided in the latest Linux kernel updates.

3

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

CVE-2024-57841 affects multiple versions of the Linux kernel, including versions between 5.15.162 to 5.15.176, 6.1.97 to 6.1.124, and several others.

4

What does CVE-2024-57841 impact?

CVE-2024-57841 impacts the Linux kernel's networking subsystem, specifically related to TCP connection requests.

5

Is CVE-2024-57841 publicly known?

Yes, CVE-2024-57841 is a publicly disclosed vulnerability tracked in the CVE database.

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