CVE-2023-1668 Overview
A flaw was discovered in Open vSwitch (OVS), a widely deployed virtual switch implementation used in cloud and enterprise network environments. When processing an IP packet with protocol 0, OVS installs a datapath flow without the action modifying the IP header. This results in the installation of a datapath flow matching all IP protocols (nw_proto is wildcarded) with an incorrect action, potentially causing incorrect handling of other IP packets with a non-zero IP protocol that match this datapath flow.
Critical Impact
This vulnerability can lead to incorrect packet handling across network traffic, potentially causing denial of service conditions and unauthorized information disclosure in virtualized network environments running Open vSwitch.
Affected Products
- Cloudbase Open vSwitch (versions prior to patched releases including 3.1.0)
- Debian Linux 11.0
- Red Hat OpenShift Container Platform 4.0
- Red Hat OpenStack Platform 16.1, 16.2, 17.0
- Red Hat Virtualization 4.0
- Red Hat Fast Datapath
- Red Hat Enterprise Linux 7.0 and 8.0
Discovery Timeline
- April 6, 2023 - Vulnerability publicly disclosed via Openwall OSS Security Discussion
- April 10, 2023 - CVE-2023-1668 published to NVD
- April 23, 2025 - Last updated in NVD database
Technical Details for CVE-2023-1668
Vulnerability Analysis
This vulnerability (CWE-670: Always-Incorrect Control Flow Implementation) stems from improper handling of IP packets with protocol field set to 0 in the Open vSwitch datapath processing logic. When such packets are processed, OVS creates flow rules that inadvertently match against all IP protocols due to wildcarding of the nw_proto field, while associating these rules with incorrect forwarding actions.
The impact is significant for network infrastructure relying on OVS, as the misconfigured flow rules can persist in both kernel and userspace datapaths, affecting subsequent legitimate traffic that matches the overly broad flow criteria. This can result in packets being forwarded incorrectly, dropped, or processed with unintended modifications.
Root Cause
The root cause lies in the control flow logic within OVS packet processing. When an IP packet arrives with protocol 0, the flow installation routine fails to properly scope the flow rule to only match protocol 0 packets. Instead, it creates a wildcard match on the protocol field (nw_proto), causing the flow to incorrectly match all IP traffic. The associated action, derived from the original protocol 0 packet context, is then inappropriately applied to unrelated traffic.
Attack Vector
An attacker with network access can exploit this vulnerability by sending crafted IP packets with protocol field set to 0 to a system running a vulnerable version of Open vSwitch. The attack does not require authentication or user interaction, making it remotely exploitable from the network. Once the malicious flow is installed, legitimate traffic traversing the same OVS instance may be incorrectly processed, leading to service disruption or information leakage.
The exploitation involves crafting IP packets with the protocol field (byte offset 9 in the IPv4 header) set to 0x00. When these packets traverse an OVS switch, the datapath installs a flow entry with wildcarded protocol matching. Subsequent IP packets with any protocol value (TCP, UDP, ICMP, etc.) may then match this flow and be processed incorrectly according to the action defined for the protocol 0 traffic.
Detection Methods for CVE-2023-1668
Indicators of Compromise
- Unexpected flow entries in OVS with wildcarded nw_proto fields visible via ovs-dpctl dump-flows or ovs-ofctl dump-flows
- Network connectivity issues or packet loss for specific protocols in virtualized environments
- Anomalous packet forwarding behavior reported by network monitoring tools
- Presence of IP packets with protocol 0 in network captures
Detection Strategies
- Monitor OVS flow tables for entries with wildcarded protocol fields that should be specific
- Implement network IDS rules to detect IP packets with protocol field set to 0
- Deploy packet capture analysis at network boundaries to identify anomalous IP protocol 0 traffic
- Review OVS logs for unusual flow installation patterns
Monitoring Recommendations
- Enable OVS debug logging to capture flow installation events and analyze for suspicious patterns
- Implement periodic auditing of datapath flows using ovs-dpctl dump-flows to detect wildcarded entries
- Configure network monitoring to alert on unexpected changes in traffic patterns
- Establish baseline flow behavior to detect anomalies introduced by this vulnerability
How to Mitigate CVE-2023-1668
Immediate Actions Required
- Update Open vSwitch to the latest patched version from your distribution's security repository
- Apply available security patches from Red Hat, Debian, Fedora, or Gentoo as applicable
- Review and clear any suspicious flow entries using ovs-dpctl del-flows followed by proper flow repopulation
- Monitor network traffic for any signs of exploitation during the patching window
Patch Information
Security patches have been released by multiple vendors. Consult the following resources for patch availability:
- Red Hat Bug Report #2137666 - Red Hat tracking and patches
- Debian Security Advisory DSA-5387 - Debian stable patches
- Debian LTS Announcement - Debian LTS updates
- Fedora Package Announcement - Fedora updates
- Gentoo GLSA 202311-16 - Gentoo security advisory
Workarounds
- Implement network filtering at the perimeter to drop IP packets with protocol 0 before they reach OVS instances
- Configure OpenFlow rules to explicitly handle or drop protocol 0 packets at ingress points
- Segment networks to limit the blast radius of potential exploitation
- Monitor and manually clear affected flow entries as a temporary measure until patches can be applied
# Configuration example - Drop protocol 0 packets at ingress
# Add OpenFlow rule to drop IP packets with protocol 0
ovs-ofctl add-flow br0 "priority=65535,ip,nw_proto=0,actions=drop"
# Verify the rule is installed
ovs-ofctl dump-flows br0 | grep "nw_proto=0"
# Clear potentially affected flows from datapath
ovs-dpctl del-flows
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.


