Module etherparse::ip_number
source · Expand description
u8
constants for the most used ip protocol numbers.
The constants only exist for convenience. You can get equivalent values by
casting the enum values of IpNumber
to a u8 value.
use etherparse::{ip_number, IpNumber};
assert_eq!(ip_number::TCP, IpNumber::Tcp as u8);
The list original values were copied from https://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml