Skip to main content

extract_ip

Function extract_ip 

Source
pub fn extract_ip(frame: &[u8]) -> Option<(IpHeader, &[u8])>
Expand description

Extracts the IPv4 header and payload from a raw Ethernet frame, transparently handling untagged, 802.1Q, and 802.1ad Q-in-Q framing.