Vulnerability · Published Jan 31, 2025 · Assigned by Linux

CVE-2025-21681openvswitch: fix lockup on tx to unregistering netdev with carrier

Medium 5.5

In plain English

A medium-severity security flaw in Linux from Linux. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.2% (higher than 12% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS NVD)5.5Medium
Exploit odds (30 days)0.2%top 88.0% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

In the Linux kernel, the following vulnerability has been resolved: openvswitch: fix lockup on tx to unregistering netdev with carrier Commit in a fixes tag attempted to fix the issue in the following sequence of calls: do_output -> ovs_vport_send -> dev_queue_xmit -> __dev_queue_xmit -> netdev_core_pick_tx -> skb_tx_hash When device is unregistering, the 'dev->real_num_tx_queues' goes to zero and the 'while (unlikely(hash >= qcount))' loop inside the 'skb_tx_hash' becomes infinite, locking up the core forever. But unfortunately, checking just the carrier status is not enough to fix the issue, because some devices may still be in unregistering state while reporting carrier status OK. One example of such device is a net/dummy. It sets carrier ON on start, but it doesn't implement .ndo_stop to set the carrier off. And it makes sense, because dummy doesn't really have a carrier. Therefore, while this device is unregistering, it's still easy to hit the infinite loop in the skb_tx_hash() from the OVS datapath. There might be other drivers that do the same, but dummy by itself is important for the OVS ecosystem, because it is frequently used as a packet sink for tcpdump while debugging OVS deployments. And when the issue is hit, the only way to recover is to reboot. Fix that by also checking if the device is running. The running state is handled by the net core during unregistering, so it covers unregistering case better, and we don't really need to send packets to devices that are not running anyway. While only checking the running state might be enough, the carrier check is preserved. The running and the carrier states seem disjoined throughout the code and different drivers. And other core functions like __dev_direct_xmit() check both before attempting to transmit a packet. So, it seems safer to check both flags in OVS as well.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:12linux6.1.128-1DEBIAN-CVE-2025-21681
Debian:13linux6.12.11-1DEBIAN-CVE-2025-21681
Debian:14linux6.12.11-1DEBIAN-CVE-2025-21681
Ubuntu:24.04:LTSlinux6.8.0-62.65USN-7595-1
Ubuntu:24.04:LTSlinux6.8.0-62.65UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-allwinner-5.19no fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-aws6.8.0-1030.32USN-7595-1
Ubuntu:24.04:LTSlinux-aws6.8.0-1030.32UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-aws-5.19no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-aws-6.2no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-aws-6.5no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-aws-6.86.8.0-1030.32~22.04.1USN-7595-1
Ubuntu:22.04:LTSlinux-aws-6.86.8.0-1030.32~22.04.1UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-azure6.8.0-1030.35UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-azure6.8.0-1030.35USN-7596-1
Ubuntu:22.04:LTSlinux-azure-5.19no fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-azure-6.116.11.0-1013.13~24.04.1UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-azure-6.116.11.0-1013.13~24.04.1USN-7448-1
Ubuntu:22.04:LTSlinux-azure-6.2no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-azure-6.5no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-azure-6.86.8.0-1030.35~22.04.1USN-7596-1
Ubuntu:22.04:LTSlinux-azure-6.86.8.0-1030.35~22.04.1UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-azure-fde-5.19no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-azure-fde-6.2no fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-azure-nvidia6.8.0-1018.19UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-azure-nvidia6.8.0-1018.19USN-7596-2
Ubuntu:24.04:LTSlinux-gcp6.8.0-1031.33USN-7595-5
Ubuntu:24.04:LTSlinux-gcp6.8.0-1031.33UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-gcp-5.19no fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-gcp-6.116.11.0-1013.13~24.04.1UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-gcp-6.2no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-gcp-6.5no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-gcp-6.86.8.0-1031.33~22.04.1UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-gcp-6.86.8.0-1031.33~22.04.1USN-7595-5
Ubuntu:24.04:LTSlinux-gke6.8.0-1026.30UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-gke6.8.0-1026.30USN-7595-1
Ubuntu:24.04:LTSlinux-gkeop6.8.0-1013.15USN-7595-1
Ubuntu:24.04:LTSlinux-gkeop6.8.0-1013.15UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-hwe-5.19no fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-hwe-6.116.11.0-24.24~24.04.1USN-7445-1
Ubuntu:24.04:LTSlinux-hwe-6.116.11.0-24.24~24.04.1UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-hwe-6.2no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-hwe-6.5no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-hwe-6.86.8.0-64.67~22.04.1UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-ibm6.8.0-1027.27USN-7595-1
Ubuntu:24.04:LTSlinux-ibm6.8.0-1027.27UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-ibm-6.86.8.0-1027.27~22.04.1UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-intel-iot-realtimeno fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-lowlatency6.8.0-62.65.1UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-lowlatency6.8.0-62.65.1USN-7595-1
Ubuntu:22.04:LTSlinux-lowlatency-hwe-5.19no fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-lowlatency-hwe-6.116.11.0-1012.13~24.04.1UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-lowlatency-hwe-6.116.11.0-1012.13~24.04.1USN-7445-1
Ubuntu:22.04:LTSlinux-lowlatency-hwe-6.2no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-lowlatency-hwe-6.5no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-lowlatency-hwe-6.86.8.0-62.65.1~22.04.1UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-lowlatency-hwe-6.86.8.0-62.65.1~22.04.1USN-7595-1
Ubuntu:24.04:LTSlinux-nvidia6.8.0-1029.32USN-7595-1
Ubuntu:24.04:LTSlinux-nvidia6.8.0-1029.32UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-nvidia-6.116.11.0-1007.7UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-nvidia-6.2no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-nvidia-6.5no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-nvidia-6.86.8.0-1029.32~22.04.1USN-7595-1
Ubuntu:22.04:LTSlinux-nvidia-6.86.8.0-1029.32~22.04.1UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-nvidia-lowlatency6.8.0-1029.32.1USN-7595-1
Ubuntu:24.04:LTSlinux-nvidia-lowlatency6.8.0-1029.32.1UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-nvidia-tegra6.8.0-1008.8UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-oem-5.17no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-oem-6.0no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-oem-6.1no fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-oem-6.116.11.0-1020.20USN-7445-1
Ubuntu:24.04:LTSlinux-oem-6.116.11.0-1020.20UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-oem-6.5no fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-oem-6.86.8.0-1029.29USN-7595-1
Ubuntu:24.04:LTSlinux-oem-6.86.8.0-1029.29UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-oracle6.8.0-1027.28UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-oracle6.8.0-1027.28USN-7595-4
Ubuntu:22.04:LTSlinux-oracle-6.5no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-oracle-6.86.8.0-1027.28~22.04.1USN-7595-4
Ubuntu:22.04:LTSlinux-oracle-6.86.8.0-1027.28~22.04.1UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-raspi6.8.0-1029.33UBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-raspi6.8.0-1029.33USN-7595-4
Ubuntu:24.04:LTSlinux-raspi-realtimeno fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-realtimeno fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-realtimeno fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-riscvno fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-riscvno fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-riscv-5.19no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-riscv-6.5no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-riscv-6.86.8.0-62.65~22.04.1UBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-starfive-5.19no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-starfive-6.2no fix listedUBUNTU-CVE-2025-21681
Ubuntu:22.04:LTSlinux-starfive-6.5no fix listedUBUNTU-CVE-2025-21681
Ubuntu:24.04:LTSlinux-xilinx6.8.0-1017.18UBUNTU-CVE-2025-21681

Affected products (as reported)

VendorProductVersions
Linux Linux 9b0dd09c1ceb35950d2884848099fccc9ec9a123 – before b5c73fc92f8d15c16e5dc87b5c17d2abf1e6d092284be5db6c8d06d247ed056cfc448c4f79bbb16c – before 87fcf0d137c770e6040ebfdb0abd8e7dd481b5045efcb301523baacd98a47553d4996e924923114d – before 930268823f6bccb697aa5d2047aeffd4a497308c644b3051b06ba465bc7401bfae9b14963cbc8c1c – before ea9e990356b7bee95440ba0e6e83cc4d701afaca066b86787fa3d97b7aefb5ac0a99a22dad2d15f8 – before ea966b6698785fb9cd0fdb867acd91b222e4723f066b86787fa3d97b7aefb5ac0a99a22dad2d15f8 – before 82f433e8dd0629e16681edf6039d094b5518d8ed066b86787fa3d97b7aefb5ac0a99a22dad2d15f8 – before 47e55e4b410f7d552e43011baa5be1aab409399056252da41426f3d01957456f13caf46ce670ea29
Linux Linux 6.3

References