Executive brief
A vulnerability in the Linux kernel's network tunneling driver (TUN) could allow an attacker to cause a system crash or significant performance degradation. By sending a flood of specially crafted, invalid network packets, an attacker can force the system to spend all its processing power logging error messages to the console. This leads to a 'soft lockup' where the system becomes unresponsive, potentially disrupting hosted services and virtual machines.
Technical details
A resource exhaustion vulnerability exists in the Linux kernel's TUN device driver (drivers/net/tun.c). When the `vhost_worker` process receives illegal packets via TUN callbacks, the `tun_do_read` function performs a hex dump of the packet contents to the system console without rate limiting. If a large volume of such packets is received while console logging is enabled, the overhead of serial/console I/O can consume excessive CPU time, triggering a soft lockup. This is classified as CWE-770 (Allocation of Resources Without Limits or Throttling). The fix introduces the `net_ratelimit()` mechanism to throttle these log messages.
Affected products
- Linux Linux Kernel Fixed in 6.9, 6.8.8, 6.6.29, 6.1.88, 5.15.157, 5.10.216, 5.4.275, 4.19.313
Timeline
- 2024-04-14: patched: Initial patch authored
- 2024-05-01: advisory: CVE-2024-27013 published
References
- https://git.kernel.org/stable/c/14cdb43dbc827e18ac7d5b30c5b4c676219f1421
- https://git.kernel.org/stable/c/40f4ced305c6c47487d3cd8da54676e2acc1a6ad
- https://git.kernel.org/stable/c/4b0dcae5c4797bf31c63011ed62917210d3fdac3
- https://git.kernel.org/stable/c/52854101180beccdb9dc2077a3bea31b6ad48dfa
- https://git.kernel.org/stable/c/62e27ef18eb4f0d33bbae8e9ef56b99696a74713
- https://git.kernel.org/stable/c/68459b8e3ee554ce71878af9eb69659b9462c588
- https://git.kernel.org/stable/c/a50dbeca28acf7051dfa92786b85f704c75db6eb