Struct mutnet::data_buffer::DataBuffer
source · pub struct DataBuffer<B, HM>{ /* private fields */ }
Expand description
Wraps the data buffer and contains metadata about the parsed protocols.
Implementations§
source§impl<B, PHM> DataBuffer<B, Arp<PHM>>
impl<B, PHM> DataBuffer<B, Arp<PHM>>
sourcepub fn parse_arp_alone(
buf: B,
headroom: usize
) -> Result<DataBuffer<B, Arp<NoPreviousHeader>>, ParseArpError>
pub fn parse_arp_alone( buf: B, headroom: usize ) -> Result<DataBuffer<B, Arp<NoPreviousHeader>>, ParseArpError>
Parses buf
and creates a new DataBuffer
for an ARP layer with no previous layers.
headroom
indicates the amount of headroom in the provided buf
.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- the provided ARP packet’s hardware type is not Ethernet or IPv4.
sourcepub fn parse_arp_layer(
lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>
) -> Result<DataBuffer<B, Arp<PHM>>, ParseArpError>
pub fn parse_arp_layer( lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM> ) -> Result<DataBuffer<B, Arp<PHM>>, ParseArpError>
Consumes the lower_layer_data_buffer
and creates a new DataBuffer
with an additional
ARP layer.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- the provided ARP packet’s hardware type is not Ethernet or IPv4.
source§impl<B> DataBuffer<B, Eth>
impl<B> DataBuffer<B, Eth>
sourcepub fn parse_ethernet_layer(
buf: B,
headroom: usize
) -> Result<DataBuffer<B, Eth>, UnexpectedBufferEndError>
pub fn parse_ethernet_layer( buf: B, headroom: usize ) -> Result<DataBuffer<B, Eth>, UnexpectedBufferEndError>
Parses data and creates a new DataBuffer
for an Ethernet layer.
The provided headroom
indicates the amount of headroom in the provided buf
.
§Errors
Returns an error if the provided data buffer is shorter than expected.
source§impl<B, PHM> DataBuffer<B, Ieee802_1QVlan<PHM>>
impl<B, PHM> DataBuffer<B, Ieee802_1QVlan<PHM>>
sourcepub fn parse_ieee802_1q_alone(
buf: B,
headroom: usize,
expected_vlan_tags: Vlan
) -> Result<DataBuffer<B, Ieee802_1QVlan<NoPreviousHeader>>, ParseIeee802_1QError>
pub fn parse_ieee802_1q_alone( buf: B, headroom: usize, expected_vlan_tags: Vlan ) -> Result<DataBuffer<B, Ieee802_1QVlan<NoPreviousHeader>>, ParseIeee802_1QError>
Parses buf
and creates a new DataBuffer
for an IEEE 802.1Q layer with no previous layers.
headroom
indicates the amount of headroom in the provided buf
.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- no customer tag is found if
expected_vlan_tag
indicates double tagging.
sourcepub fn parse_ieee802_1q_layer(
lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>,
expected_vlan_tag: Vlan
) -> Result<DataBuffer<B, Ieee802_1QVlan<PHM>>, ParseIeee802_1QError>
pub fn parse_ieee802_1q_layer( lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>, expected_vlan_tag: Vlan ) -> Result<DataBuffer<B, Ieee802_1QVlan<PHM>>, ParseIeee802_1QError>
Consumes the lower_layer_data_buffer
and creates a new DataBuffer
with an additional
IEEE 802.1Q layer.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- no customer tag is found if
expected_vlan_tag
indicates double tagging.
source§impl<B, PHM> DataBuffer<B, Ipv4<PHM>>
impl<B, PHM> DataBuffer<B, Ipv4<PHM>>
sourcepub fn parse_ipv4_alone(
buf: B,
headroom: usize,
check_ipv4_checksum: bool
) -> Result<DataBuffer<B, Ipv4<NoPreviousHeader>>, ParseIpv4Error>
pub fn parse_ipv4_alone( buf: B, headroom: usize, check_ipv4_checksum: bool ) -> Result<DataBuffer<B, Ipv4<NoPreviousHeader>>, ParseIpv4Error>
Parses buf
and creates a new DataBuffer
for an IPv4 layer with no previous layers.
headroom
indicates the amount of headroom in the provided buf
.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- the version field is not four.
- the IHL field or total length field values are invalid.
- if
check_ipv4_checksum
is true and the checksum is invalid.
sourcepub fn parse_ipv4_layer(
lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>,
check_ipv4_checksum: bool
) -> Result<DataBuffer<B, Ipv4<PHM>>, ParseIpv4Error>
pub fn parse_ipv4_layer( lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>, check_ipv4_checksum: bool ) -> Result<DataBuffer<B, Ipv4<PHM>>, ParseIpv4Error>
Consumes the lower_layer_data_buffer
and creates a new DataBuffer
with an additional
IPv4 layer.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- the version field is not four.
- the IHL field or total length field values are invalid.
- if
check_ipv4_checksum
is true and the checksum is invalid.
source§impl<B, PHM> DataBuffer<B, Ipv6<PHM>>
impl<B, PHM> DataBuffer<B, Ipv6<PHM>>
sourcepub fn parse_ipv6_alone(
buf: B,
headroom: usize
) -> Result<DataBuffer<B, Ipv6<NoPreviousHeader>>, ParseIpv6Error>
pub fn parse_ipv6_alone( buf: B, headroom: usize ) -> Result<DataBuffer<B, Ipv6<NoPreviousHeader>>, ParseIpv6Error>
Parses buf
and creates a new DataBuffer
for an IPv6 layer with no previous layers.
headroom
indicates the amount of headroom in the provided buf
.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- the version field is not six.
sourcepub fn parse_ipv6_layer(
lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>
) -> Result<DataBuffer<B, Ipv6<PHM>>, ParseIpv6Error>
pub fn parse_ipv6_layer( lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM> ) -> Result<DataBuffer<B, Ipv6<PHM>>, ParseIpv6Error>
Consumes the lower_layer_data_buffer
and creates a new DataBuffer
with an additional
IPv6 layer.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- the version field is not six.
source§impl<B, PHM, const MAX_EXTENSIONS: usize> DataBuffer<B, Ipv6Extensions<PHM, MAX_EXTENSIONS>>
impl<B, PHM, const MAX_EXTENSIONS: usize> DataBuffer<B, Ipv6Extensions<PHM, MAX_EXTENSIONS>>
sourcepub fn parse_ipv6_extensions_alone(
buf: B,
headroom: usize,
next_header_byte: Ipv6ExtensionType
) -> Result<(DataBuffer<B, Ipv6Extensions<NoPreviousHeader, MAX_EXTENSIONS>>, bool), ParseIpv6ExtensionsError>
pub fn parse_ipv6_extensions_alone( buf: B, headroom: usize, next_header_byte: Ipv6ExtensionType ) -> Result<(DataBuffer<B, Ipv6Extensions<NoPreviousHeader, MAX_EXTENSIONS>>, bool), ParseIpv6ExtensionsError>
Parses buf
and creates a new DataBuffer
for an IPv6 extensions layer with no previous layers.
headroom
indicates the amount of headroom in the provided buf
.
The returned boolean indicates whether the payload is fragmented.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- more extensions than
MAX_EXTENSIONS
are present. - an unrecognized extension type is passed to the constructor of
Ipv6Extensions
(this constitutes a bug).
sourcepub fn parse_ipv6_extensions_layer(
lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>,
first_extension: Ipv6ExtensionType
) -> Result<(DataBuffer<B, Ipv6Extensions<PHM, MAX_EXTENSIONS>>, bool), ParseIpv6ExtensionsError>
pub fn parse_ipv6_extensions_layer( lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>, first_extension: Ipv6ExtensionType ) -> Result<(DataBuffer<B, Ipv6Extensions<PHM, MAX_EXTENSIONS>>, bool), ParseIpv6ExtensionsError>
Consumes the lower_layer_data_buffer
and creates a new DataBuffer
with an additional
IPv6 extensions layer.
The returned boolean indicates whether the payload is fragmented.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- more extensions than
MAX_EXTENSIONS
are present. - an unrecognized extension type is passed to the constructor of
Ipv6Extensions
(this constitutes a bug).
source§impl<B, PHM> DataBuffer<B, Tcp<PHM>>where
B: AsRef<[u8]>,
PHM: HeaderMetadata + HeaderMetadataMut + Copy,
DataBuffer<B, Tcp<PHM>>: PseudoHeaderChecksum,
impl<B, PHM> DataBuffer<B, Tcp<PHM>>where
B: AsRef<[u8]>,
PHM: HeaderMetadata + HeaderMetadataMut + Copy,
DataBuffer<B, Tcp<PHM>>: PseudoHeaderChecksum,
sourcepub fn parse_tcp_alone(
buf: B,
headroom: usize
) -> Result<DataBuffer<B, Tcp<NoPreviousHeader>>, ParseTcpError>
pub fn parse_tcp_alone( buf: B, headroom: usize ) -> Result<DataBuffer<B, Tcp<NoPreviousHeader>>, ParseTcpError>
Parses buf
and creates a new DataBuffer
for an TCP layer with no previous layers.
headroom
indicates the amount of headroom in the provided buf
.
No checksum can be calculated without underlying header for the pseudo header.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- the data offset field value is invalid.
sourcepub fn parse_tcp_layer(
lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>,
check_tcp_checksum: bool
) -> Result<DataBuffer<B, Tcp<PHM>>, ParseTcpError>
pub fn parse_tcp_layer( lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>, check_tcp_checksum: bool ) -> Result<DataBuffer<B, Tcp<PHM>>, ParseTcpError>
Consumes the lower_layer_data_buffer
and creates a new DataBuffer
with an additional
TCP layer.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- the data offset field value is invalid.
- if
check_tcp_checksum
is true and the checksum is invalid.
source§impl<B, PHM> DataBuffer<B, Udp<PHM>>where
B: AsRef<[u8]>,
PHM: HeaderMetadata + HeaderMetadataMut + Copy,
DataBuffer<B, Udp<PHM>>: PseudoHeaderChecksum,
impl<B, PHM> DataBuffer<B, Udp<PHM>>where
B: AsRef<[u8]>,
PHM: HeaderMetadata + HeaderMetadataMut + Copy,
DataBuffer<B, Udp<PHM>>: PseudoHeaderChecksum,
sourcepub fn parse_udp_alone(
buf: B,
headroom: usize
) -> Result<DataBuffer<B, Udp<NoPreviousHeader>>, ParseUdpError>
pub fn parse_udp_alone( buf: B, headroom: usize ) -> Result<DataBuffer<B, Udp<NoPreviousHeader>>, ParseUdpError>
Parses buf
and creates a new DataBuffer
for an UDP layer with no previous layers.
headroom
indicates the amount of headroom in the provided buf
.
No checksum can be calculated without underlying header for the pseudo header.
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- the length field value is invalid.
sourcepub fn parse_udp_layer(
lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>,
check_udp_checksum: bool
) -> Result<DataBuffer<B, Udp<PHM>>, ParseUdpError>
pub fn parse_udp_layer( lower_layer_data_buffer: impl HeaderMetadata + Payload + BufferIntoInner<B> + HeaderMetadataExtraction<PHM>, check_udp_checksum: bool ) -> Result<DataBuffer<B, Udp<PHM>>, ParseUdpError>
Consumes the lower_layer_data_buffer
and creates a new DataBuffer
with an additional
UDP layer.
§Note
Inconsistencies between the IP payload length allocated for the UDP datagram and the UDP length are permissible as long as the indicated IP payload length is larger than the UDP length. https://datatracker.ietf.org/doc/html/rfc768 https://datatracker.ietf.org/doc/html/draft-ietf-tsvwg-udp-options-01#section-9
§Errors
Returns an error if:
- the provided data buffer is shorter than expected.
- the length field value is invalid.
- if
check_udp_checksum
is true and the checksum is invalid.
Trait Implementations§
source§impl<B, HM> ArpMethods for DataBuffer<B, HM>
impl<B, HM> ArpMethods for DataBuffer<B, HM>
source§fn arp_hardware_type(&self) -> u16
fn arp_hardware_type(&self) -> u16
source§fn arp_protocol_type(&self) -> u16
fn arp_protocol_type(&self) -> u16
source§fn arp_typed_protocol_type(
&self
) -> Result<EtherType, UnrecognizedEtherTypeError>
fn arp_typed_protocol_type( &self ) -> Result<EtherType, UnrecognizedEtherTypeError>
source§fn arp_operation_code(&self) -> u16
fn arp_operation_code(&self) -> u16
source§fn arp_typed_operation_code(
&self
) -> Result<OperationCode, UnrecognizedOperationCodeError>
fn arp_typed_operation_code( &self ) -> Result<OperationCode, UnrecognizedOperationCodeError>
OperationCode
. Read moresource§fn arp_hardware_address_length(&self) -> u8
fn arp_hardware_address_length(&self) -> u8
source§fn arp_protocol_address_length(&self) -> u8
fn arp_protocol_address_length(&self) -> u8
source§fn arp_sender_hardware_address(&self) -> MacAddress
fn arp_sender_hardware_address(&self) -> MacAddress
source§fn arp_sender_protocol_address(&self) -> Ipv4Addr
fn arp_sender_protocol_address(&self) -> Ipv4Addr
source§fn arp_target_hardware_address(&self) -> MacAddress
fn arp_target_hardware_address(&self) -> MacAddress
source§fn arp_target_protocol_address(&self) -> Ipv4Addr
fn arp_target_protocol_address(&self) -> Ipv4Addr
source§impl<B, HM> ArpMethodsMut for DataBuffer<B, HM>
impl<B, HM> ArpMethodsMut for DataBuffer<B, HM>
source§fn set_arp_operation_code(&mut self, operation_code: OperationCode)
fn set_arp_operation_code(&mut self, operation_code: OperationCode)
source§fn set_arp_sender_hardware_address(&mut self, sender_addr: &MacAddress)
fn set_arp_sender_hardware_address(&mut self, sender_addr: &MacAddress)
source§fn set_arp_sender_protocol_address(&mut self, sender_addr: &Ipv4Addr)
fn set_arp_sender_protocol_address(&mut self, sender_addr: &Ipv4Addr)
source§fn set_arp_target_hardware_address(&mut self, target_addr: &MacAddress)
fn set_arp_target_hardware_address(&mut self, target_addr: &MacAddress)
source§fn set_arp_target_protocol_address(&mut self, target_addr: &Ipv4Addr)
fn set_arp_target_protocol_address(&mut self, target_addr: &Ipv4Addr)
source§impl<B, HM> BufferIntoInner<B> for DataBuffer<B, HM>
impl<B, HM> BufferIntoInner<B> for DataBuffer<B, HM>
source§fn data_length(&self) -> usize
fn data_length(&self) -> usize
source§fn buffer_into_inner(self) -> B
fn buffer_into_inner(self) -> B
source§fn buffer_get_ref(&self) -> &[u8] ⓘ
fn buffer_get_ref(&self) -> &[u8] ⓘ
source§impl<B, HM> Clone for DataBuffer<B, HM>
impl<B, HM> Clone for DataBuffer<B, HM>
source§impl<B, HM> Debug for DataBuffer<B, HM>
impl<B, HM> Debug for DataBuffer<B, HM>
source§impl<B, HM> EthernetMethods for DataBuffer<B, HM>
impl<B, HM> EthernetMethods for DataBuffer<B, HM>
source§fn ethernet_destination(&self) -> MacAddress
fn ethernet_destination(&self) -> MacAddress
source§fn ethernet_source(&self) -> MacAddress
fn ethernet_source(&self) -> MacAddress
source§fn ethernet_ether_type(&self) -> u16
fn ethernet_ether_type(&self) -> u16
source§fn ethernet_typed_ether_type(
&self
) -> Result<EtherType, UnrecognizedEtherTypeError>
fn ethernet_typed_ether_type( &self ) -> Result<EtherType, UnrecognizedEtherTypeError>
source§impl<B, HM> EthernetMethodsMut for DataBuffer<B, HM>
impl<B, HM> EthernetMethodsMut for DataBuffer<B, HM>
source§fn set_ethernet_destination(&mut self, mac_addr: &MacAddress)
fn set_ethernet_destination(&mut self, mac_addr: &MacAddress)
source§fn set_ethernet_source(&mut self, mac_addr: &MacAddress)
fn set_ethernet_source(&mut self, mac_addr: &MacAddress)
source§fn set_ethernet_ether_type(&mut self, ether_type: EtherType)
fn set_ethernet_ether_type(&mut self, ether_type: EtherType)
source§impl<B, HM> Hash for DataBuffer<B, HM>
impl<B, HM> Hash for DataBuffer<B, HM>
source§impl<B, HM> Ieee802_1QMethods for DataBuffer<B, HM>
impl<B, HM> Ieee802_1QMethods for DataBuffer<B, HM>
source§fn ieee802_1q_c_tag_control_information(&self) -> [u8; 2]
fn ieee802_1q_c_tag_control_information(&self) -> [u8; 2]
source§fn ieee802_1q_c_tag_priority_code_point(&self) -> u8
fn ieee802_1q_c_tag_priority_code_point(&self) -> u8
source§fn ieee802_1q_c_tag_drop_eligible_indicator(&self) -> bool
fn ieee802_1q_c_tag_drop_eligible_indicator(&self) -> bool
source§fn ieee802_1q_c_tag_vlan_identifier(&self) -> u16
fn ieee802_1q_c_tag_vlan_identifier(&self) -> u16
source§fn ieee802_1q_s_tag_control_information(&self) -> Option<[u8; 2]>
fn ieee802_1q_s_tag_control_information(&self) -> Option<[u8; 2]>
source§fn ieee802_1q_s_tag_priority_code_point(&self) -> Option<u8>
fn ieee802_1q_s_tag_priority_code_point(&self) -> Option<u8>
source§fn ieee802_1q_s_tag_drop_eligible_indicator(&self) -> Option<bool>
fn ieee802_1q_s_tag_drop_eligible_indicator(&self) -> Option<bool>
source§fn ieee802_1q_s_tag_vlan_identifier(&self) -> Option<u16>
fn ieee802_1q_s_tag_vlan_identifier(&self) -> Option<u16>
source§fn ieee802_1q_typed_vlan(&self) -> Vlan
fn ieee802_1q_typed_vlan(&self) -> Vlan
Vlan
indicating whether the IEEE802.1Q header is single or double tagged.source§fn ieee802_1q_ether_type(&self) -> u16
fn ieee802_1q_ether_type(&self) -> u16
source§fn ieee802_1q_typed_ether_type(
&self
) -> Result<EtherType, UnrecognizedEtherTypeError>
fn ieee802_1q_typed_ether_type( &self ) -> Result<EtherType, UnrecognizedEtherTypeError>
source§impl<B, HM> Ieee802_1QMethodsMut for DataBuffer<B, HM>where
B: AsRef<[u8]> + AsMut<[u8]>,
HM: HeaderMetadata + HeaderMetadataMut + Ieee802_1QVlanMarker,
DataBuffer<B, HM>: UpdateEtherTypeBelowIeee802_1q,
impl<B, HM> Ieee802_1QMethodsMut for DataBuffer<B, HM>where
B: AsRef<[u8]> + AsMut<[u8]>,
HM: HeaderMetadata + HeaderMetadataMut + Ieee802_1QVlanMarker,
DataBuffer<B, HM>: UpdateEtherTypeBelowIeee802_1q,
source§fn set_ieee802_1q_c_tag_control_information(
&mut self,
tag_control_information: &[u8; 2]
)
fn set_ieee802_1q_c_tag_control_information( &mut self, tag_control_information: &[u8; 2] )
source§fn set_ieee802_1q_c_tag_priority_code_point(&mut self, priority_code_point: u8)
fn set_ieee802_1q_c_tag_priority_code_point(&mut self, priority_code_point: u8)
source§fn set_ieee802_1q_c_tag_drop_eligible_indicator(
&mut self,
drop_eligible_indicator: bool
)
fn set_ieee802_1q_c_tag_drop_eligible_indicator( &mut self, drop_eligible_indicator: bool )
source§fn set_ieee802_1q_c_tag_vlan_identifier(&mut self, vlan_identifier: u16)
fn set_ieee802_1q_c_tag_vlan_identifier(&mut self, vlan_identifier: u16)
source§fn add_or_update_ieee802_1q_s_tag(
&mut self,
s_tag_control_information: &[u8; 2]
) -> Result<(), NotEnoughHeadroomError>
fn add_or_update_ieee802_1q_s_tag( &mut self, s_tag_control_information: &[u8; 2] ) -> Result<(), NotEnoughHeadroomError>
source§fn set_ieee802_1q_s_tag_priority_code_point(
&mut self,
priority_code_point: u8
) -> Result<(), NotDoubleTaggedError>
fn set_ieee802_1q_s_tag_priority_code_point( &mut self, priority_code_point: u8 ) -> Result<(), NotDoubleTaggedError>
source§fn set_ieee802_1q_s_tag_drop_eligible_indicator(
&mut self,
drop_eligible_indicator: bool
) -> Result<(), NotDoubleTaggedError>
fn set_ieee802_1q_s_tag_drop_eligible_indicator( &mut self, drop_eligible_indicator: bool ) -> Result<(), NotDoubleTaggedError>
source§fn set_ieee802_1q_s_tag_vlan_identifier(
&mut self,
vlan_identifier: u16
) -> Result<(), NotDoubleTaggedError>
fn set_ieee802_1q_s_tag_vlan_identifier( &mut self, vlan_identifier: u16 ) -> Result<(), NotDoubleTaggedError>
source§fn cut_ieee802_1q_s_tag(&mut self)
fn cut_ieee802_1q_s_tag(&mut self)
source§fn set_ieee802_1q_ether_type(&mut self, ether_type: u16)
fn set_ieee802_1q_ether_type(&mut self, ether_type: u16)
source§impl<B, HM> Ipv4Methods for DataBuffer<B, HM>
impl<B, HM> Ipv4Methods for DataBuffer<B, HM>
source§fn ipv4_version(&self) -> u8
fn ipv4_version(&self) -> u8
source§fn ipv4_typed_dscp(&self) -> Result<Dscp, UnrecognizedDscpError>
fn ipv4_typed_dscp(&self) -> Result<Dscp, UnrecognizedDscpError>
source§fn ipv4_typed_ecn(&self) -> Result<Ecn, UnrecognizedEcnError>
fn ipv4_typed_ecn(&self) -> Result<Ecn, UnrecognizedEcnError>
source§fn ipv4_total_length(&self) -> u16
fn ipv4_total_length(&self) -> u16
source§fn ipv4_identification(&self) -> u16
fn ipv4_identification(&self) -> u16
source§fn ipv4_flags(&self) -> u8
fn ipv4_flags(&self) -> u8
source§fn ipv4_evil_flag(&self) -> bool
fn ipv4_evil_flag(&self) -> bool
source§fn ipv4_dont_fragment_flag(&self) -> bool
fn ipv4_dont_fragment_flag(&self) -> bool
source§fn ipv4_more_fragments_flag(&self) -> bool
fn ipv4_more_fragments_flag(&self) -> bool
source§fn ipv4_fragment_offset(&self) -> u16
fn ipv4_fragment_offset(&self) -> u16
source§fn ipv4_time_to_live(&self) -> u8
fn ipv4_time_to_live(&self) -> u8
source§fn ipv4_protocol(&self) -> u8
fn ipv4_protocol(&self) -> u8
source§fn ipv4_typed_protocol(
&self
) -> Result<InternetProtocolNumber, UnrecognizedInternetProtocolNumberError>
fn ipv4_typed_protocol( &self ) -> Result<InternetProtocolNumber, UnrecognizedInternetProtocolNumberError>
InternetProtocolNumber
Read moresource§fn ipv4_header_checksum(&self) -> u16
fn ipv4_header_checksum(&self) -> u16
source§fn ipv4_calculate_checksum(&self) -> u16
fn ipv4_calculate_checksum(&self) -> u16
source§fn ipv4_source(&self) -> Ipv4Addr
fn ipv4_source(&self) -> Ipv4Addr
source§fn ipv4_destination(&self) -> Ipv4Addr
fn ipv4_destination(&self) -> Ipv4Addr
source§fn ipv4_payload_length(&self) -> u16
fn ipv4_payload_length(&self) -> u16
source§impl<B, HM> Ipv4MethodsMut for DataBuffer<B, HM>
impl<B, HM> Ipv4MethodsMut for DataBuffer<B, HM>
source§fn set_ipv4_ihl(&mut self, ihl: u8) -> Result<(), SetIhlError>
fn set_ipv4_ihl(&mut self, ihl: u8) -> Result<(), SetIhlError>
source§fn set_ipv4_dscp(&mut self, dscp: Dscp)
fn set_ipv4_dscp(&mut self, dscp: Dscp)
source§fn set_ipv4_ecn(&mut self, ecn: Ecn)
fn set_ipv4_ecn(&mut self, ecn: Ecn)
source§fn set_ipv4_total_length(
&mut self,
total_length: u16
) -> Result<(), SetTotalLengthError>
fn set_ipv4_total_length( &mut self, total_length: u16 ) -> Result<(), SetTotalLengthError>
source§fn set_ipv4_identification(&mut self, identification: u16)
fn set_ipv4_identification(&mut self, identification: u16)
source§fn set_ipv4_flags(&mut self, flags: u8)
fn set_ipv4_flags(&mut self, flags: u8)
source§fn set_ipv4_evil_flag(&mut self, evil: bool)
fn set_ipv4_evil_flag(&mut self, evil: bool)
source§fn set_ipv4_dont_fragment_flag(&mut self, dont_fragment: bool)
fn set_ipv4_dont_fragment_flag(&mut self, dont_fragment: bool)
source§fn set_ipv4_more_fragments_flag(&mut self, more_fragments: bool)
fn set_ipv4_more_fragments_flag(&mut self, more_fragments: bool)
source§fn set_ipv4_fragment_offset(&mut self, fragment_offset: u16)
fn set_ipv4_fragment_offset(&mut self, fragment_offset: u16)
source§fn set_ipv4_time_to_live(&mut self, time_to_live: u8)
fn set_ipv4_time_to_live(&mut self, time_to_live: u8)
source§fn set_ipv4_protocol(&mut self, protocol: u8)
fn set_ipv4_protocol(&mut self, protocol: u8)
source§fn set_ipv4_header_checksum(&mut self, checksum: u16)
fn set_ipv4_header_checksum(&mut self, checksum: u16)
source§fn update_ipv4_header_checksum(&mut self)
fn update_ipv4_header_checksum(&mut self)
source§fn set_ipv4_source(&mut self, source: Ipv4Addr)
fn set_ipv4_source(&mut self, source: Ipv4Addr)
source§fn set_ipv4_destination(&mut self, destination: Ipv4Addr)
fn set_ipv4_destination(&mut self, destination: Ipv4Addr)
source§impl<B, HM, const MAX_EXTENSIONS: usize> Ipv6ExtMethods<MAX_EXTENSIONS> for DataBuffer<B, HM>
impl<B, HM, const MAX_EXTENSIONS: usize> Ipv6ExtMethods<MAX_EXTENSIONS> for DataBuffer<B, HM>
source§fn ipv6_ext_amount(&self) -> usize
fn ipv6_ext_amount(&self) -> usize
source§fn ipv6_extensions(&self) -> [Option<Ipv6ExtensionType>; MAX_EXTENSIONS]
fn ipv6_extensions(&self) -> [Option<Ipv6ExtensionType>; MAX_EXTENSIONS]
source§fn ipv6_ext_next_header(&self) -> Result<u8, Ipv6ExtensionIndexOutOfBoundsError>
fn ipv6_ext_next_header(&self) -> Result<u8, Ipv6ExtensionIndexOutOfBoundsError>
source§fn ipv6_ext_typed_next_header(
&self
) -> Result<InternetProtocolNumber, Ipv6ExtTypedHeaderError>
fn ipv6_ext_typed_next_header( &self ) -> Result<InternetProtocolNumber, Ipv6ExtTypedHeaderError>
InternetProtocolNumber
. Read moresource§fn ipv6_ext_per_extension_next_header(
&self,
extension_index: usize
) -> Result<u8, Ipv6ExtensionIndexOutOfBoundsError>
fn ipv6_ext_per_extension_next_header( &self, extension_index: usize ) -> Result<u8, Ipv6ExtensionIndexOutOfBoundsError>
extension_index
. Read moresource§fn ipv6_ext_per_extension_typed_next_header(
&self,
extension_index: usize
) -> Result<InternetProtocolNumber, Ipv6ExtTypedHeaderError>
fn ipv6_ext_per_extension_typed_next_header( &self, extension_index: usize ) -> Result<InternetProtocolNumber, Ipv6ExtTypedHeaderError>
source§fn ipv6_ext_length(
&self,
extension_index: usize
) -> Result<u8, Ipv6ExtFieldError>
fn ipv6_ext_length( &self, extension_index: usize ) -> Result<u8, Ipv6ExtFieldError>
extension_index
. Read moresource§fn ipv6_ext_length_in_bytes(
&self,
extension_index: usize
) -> Result<usize, Ipv6ExtensionIndexOutOfBoundsError>
fn ipv6_ext_length_in_bytes( &self, extension_index: usize ) -> Result<usize, Ipv6ExtensionIndexOutOfBoundsError>
extension_index
in bytes. Read moresource§fn ipv6_ext_data(
&self,
extension_index: usize
) -> Result<&[u8], Ipv6ExtFieldError>
fn ipv6_ext_data( &self, extension_index: usize ) -> Result<&[u8], Ipv6ExtFieldError>
extension_index
. Read moresource§fn ipv6_ext_routing_type(
&self,
extension_index: usize
) -> Result<u8, Ipv6ExtFieldError>
fn ipv6_ext_routing_type( &self, extension_index: usize ) -> Result<u8, Ipv6ExtFieldError>
extension_index
. Read moresource§fn ipv6_ext_segments_left(
&self,
extension_index: usize
) -> Result<u8, Ipv6ExtFieldError>
fn ipv6_ext_segments_left( &self, extension_index: usize ) -> Result<u8, Ipv6ExtFieldError>
extension_index
. Read moresource§fn ipv6_ext_fragment_offset(
&self,
extension_index: usize
) -> Result<u16, Ipv6ExtFieldError>
fn ipv6_ext_fragment_offset( &self, extension_index: usize ) -> Result<u16, Ipv6ExtFieldError>
extension_index
. Read moresource§fn ipv6_ext_more_fragments(
&self,
extension_index: usize
) -> Result<bool, Ipv6ExtFieldError>
fn ipv6_ext_more_fragments( &self, extension_index: usize ) -> Result<bool, Ipv6ExtFieldError>
extension_index
. Read moresource§fn ipv6_ext_fragment_identification(
&self,
extension_index: usize
) -> Result<u32, Ipv6ExtFieldError>
fn ipv6_ext_fragment_identification( &self, extension_index: usize ) -> Result<u32, Ipv6ExtFieldError>
extension_index
. Read moresource§impl<B, HM, const MAX_EXTENSIONS: usize> Ipv6ExtMethodsMut<MAX_EXTENSIONS> for DataBuffer<B, HM>where
B: AsRef<[u8]> + AsMut<[u8]>,
HM: HeaderMetadata + HeaderMetadataMut + Ipv6ExtMarker<MAX_EXTENSIONS>,
DataBuffer<B, HM>: UpdateIpv6Length,
impl<B, HM, const MAX_EXTENSIONS: usize> Ipv6ExtMethodsMut<MAX_EXTENSIONS> for DataBuffer<B, HM>where
B: AsRef<[u8]> + AsMut<[u8]>,
HM: HeaderMetadata + HeaderMetadataMut + Ipv6ExtMarker<MAX_EXTENSIONS>,
DataBuffer<B, HM>: UpdateIpv6Length,
source§fn set_ipv6_ext_next_header(
&mut self,
next_header: InternetProtocolNumber
) -> Result<(), Ipv6ExtensionIndexOutOfBoundsError>
fn set_ipv6_ext_next_header( &mut self, next_header: InternetProtocolNumber ) -> Result<(), Ipv6ExtensionIndexOutOfBoundsError>
source§fn set_ipv6_ext_length(
&mut self,
new_length: u8,
extension_index: usize
) -> Result<(), Ipv6ExtSetFieldError>
fn set_ipv6_ext_length( &mut self, new_length: u8, extension_index: usize ) -> Result<(), Ipv6ExtSetFieldError>
extension_index
. Read moresource§fn ipv6_ext_data_mut(
&mut self,
extension_index: usize
) -> Result<&mut [u8], Ipv6ExtFieldError>
fn ipv6_ext_data_mut( &mut self, extension_index: usize ) -> Result<&mut [u8], Ipv6ExtFieldError>
extension_index
. Read moresource§fn set_ipv6_ext_routing_type(
&mut self,
routing_type: RoutingType,
extension_index: usize
) -> Result<(), Ipv6ExtFieldError>
fn set_ipv6_ext_routing_type( &mut self, routing_type: RoutingType, extension_index: usize ) -> Result<(), Ipv6ExtFieldError>
extension_index
. Read moresource§fn set_ipv6_ext_segments_left(
&mut self,
segments_left: u8,
extension_index: usize
) -> Result<(), Ipv6ExtFieldError>
fn set_ipv6_ext_segments_left( &mut self, segments_left: u8, extension_index: usize ) -> Result<(), Ipv6ExtFieldError>
extension_index
. Read moresource§fn set_ipv6_ext_fragment_offset(
&mut self,
fragment_offset: u16,
extension_index: usize
) -> Result<(), Ipv6ExtFieldError>
fn set_ipv6_ext_fragment_offset( &mut self, fragment_offset: u16, extension_index: usize ) -> Result<(), Ipv6ExtFieldError>
extension_index
. Read moresource§fn set_ipv6_ext_more_fragments(
&mut self,
more_fragments: bool,
extension_index: usize
) -> Result<(), Ipv6ExtFieldError>
fn set_ipv6_ext_more_fragments( &mut self, more_fragments: bool, extension_index: usize ) -> Result<(), Ipv6ExtFieldError>
extension_index
. Read moresource§fn set_ipv6_ext_fragment_identification(
&mut self,
identification: u32,
extension_index: usize
) -> Result<(), Ipv6ExtFieldError>
fn set_ipv6_ext_fragment_identification( &mut self, identification: u32, extension_index: usize ) -> Result<(), Ipv6ExtFieldError>
extension_index
. Read moresource§impl<B, HM> Ipv6Methods for DataBuffer<B, HM>
impl<B, HM> Ipv6Methods for DataBuffer<B, HM>
source§fn ipv6_version(&self) -> u8
fn ipv6_version(&self) -> u8
source§fn ipv6_traffic_class(&self) -> u8
fn ipv6_traffic_class(&self) -> u8
source§fn ipv6_flow_label(&self) -> u32
fn ipv6_flow_label(&self) -> u32
source§fn ipv6_payload_length(&self) -> u16
fn ipv6_payload_length(&self) -> u16
source§fn ipv6_next_header(&self) -> u8
fn ipv6_next_header(&self) -> u8
source§fn ipv6_typed_next_header(
&self
) -> Result<InternetProtocolNumber, UnrecognizedInternetProtocolNumberError>
fn ipv6_typed_next_header( &self ) -> Result<InternetProtocolNumber, UnrecognizedInternetProtocolNumberError>
InternetProtocolNumber
. Read moresource§fn ipv6_hop_limit(&self) -> u8
fn ipv6_hop_limit(&self) -> u8
source§fn ipv6_source(&self) -> Ipv6Addr
fn ipv6_source(&self) -> Ipv6Addr
source§fn ipv6_destination(&self) -> Ipv6Addr
fn ipv6_destination(&self) -> Ipv6Addr
source§impl<B, HM> Ipv6MethodsMut for DataBuffer<B, HM>
impl<B, HM> Ipv6MethodsMut for DataBuffer<B, HM>
source§fn set_ipv6_traffic_class(&mut self, traffic_class: u8)
fn set_ipv6_traffic_class(&mut self, traffic_class: u8)
source§fn set_ipv6_flow_label(&mut self, flow_label: u32)
fn set_ipv6_flow_label(&mut self, flow_label: u32)
source§fn set_ipv6_payload_length(
&mut self,
payload_length: u16
) -> Result<(), SetPayloadLengthError>
fn set_ipv6_payload_length( &mut self, payload_length: u16 ) -> Result<(), SetPayloadLengthError>
source§fn set_ipv6_next_header(&mut self, next_header: u8)
fn set_ipv6_next_header(&mut self, next_header: u8)
source§fn set_ipv6_hop_limit(&mut self, hop_limit: u8)
fn set_ipv6_hop_limit(&mut self, hop_limit: u8)
source§fn set_ipv6_source(&mut self, source: Ipv6Addr)
fn set_ipv6_source(&mut self, source: Ipv6Addr)
source§fn set_ipv6_destination(&mut self, destination: Ipv6Addr)
fn set_ipv6_destination(&mut self, destination: Ipv6Addr)
source§impl<B, HM> PartialEq for DataBuffer<B, HM>
impl<B, HM> PartialEq for DataBuffer<B, HM>
source§fn eq(&self, other: &DataBuffer<B, HM>) -> bool
fn eq(&self, other: &DataBuffer<B, HM>) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl<B> Payload for DataBuffer<B, Eth>
impl<B> Payload for DataBuffer<B, Eth>
source§impl<B, PHM> Payload for DataBuffer<B, Ieee802_1QVlan<PHM>>
impl<B, PHM> Payload for DataBuffer<B, Ieee802_1QVlan<PHM>>
source§impl<B, PHM> Payload for DataBuffer<B, Ipv4<PHM>>
impl<B, PHM> Payload for DataBuffer<B, Ipv4<PHM>>
source§impl<B, PHM> Payload for DataBuffer<B, Ipv6<PHM>>
impl<B, PHM> Payload for DataBuffer<B, Ipv6<PHM>>
source§impl<B, PHM, const MAX_EXTENSIONS: usize> Payload for DataBuffer<B, Ipv6Extensions<PHM, MAX_EXTENSIONS>>
impl<B, PHM, const MAX_EXTENSIONS: usize> Payload for DataBuffer<B, Ipv6Extensions<PHM, MAX_EXTENSIONS>>
source§impl<B> Payload for DataBuffer<B, NoPreviousHeader>
impl<B> Payload for DataBuffer<B, NoPreviousHeader>
source§impl<B, PHM> Payload for DataBuffer<B, Tcp<PHM>>
impl<B, PHM> Payload for DataBuffer<B, Tcp<PHM>>
source§impl<B, PHM> Payload for DataBuffer<B, Udp<PHM>>where
B: AsRef<[u8]>,
PHM: HeaderMetadata + HeaderMetadataMut,
DataBuffer<B, Udp<PHM>>: PseudoHeaderChecksum,
impl<B, PHM> Payload for DataBuffer<B, Udp<PHM>>where
B: AsRef<[u8]>,
PHM: HeaderMetadata + HeaderMetadataMut,
DataBuffer<B, Udp<PHM>>: PseudoHeaderChecksum,
source§impl<B> PayloadMut for DataBuffer<B, Eth>
impl<B> PayloadMut for DataBuffer<B, Eth>
source§fn payload_mut(&mut self) -> &mut [u8] ⓘ
fn payload_mut(&mut self) -> &mut [u8] ⓘ
source§impl<B, PHM> PayloadMut for DataBuffer<B, Ieee802_1QVlan<PHM>>
impl<B, PHM> PayloadMut for DataBuffer<B, Ieee802_1QVlan<PHM>>
source§fn payload_mut(&mut self) -> &mut [u8] ⓘ
fn payload_mut(&mut self) -> &mut [u8] ⓘ
source§impl<B, PHM> PayloadMut for DataBuffer<B, Ipv4<PHM>>
impl<B, PHM> PayloadMut for DataBuffer<B, Ipv4<PHM>>
source§fn payload_mut(&mut self) -> &mut [u8] ⓘ
fn payload_mut(&mut self) -> &mut [u8] ⓘ
source§impl<B, PHM> PayloadMut for DataBuffer<B, Ipv6<PHM>>
impl<B, PHM> PayloadMut for DataBuffer<B, Ipv6<PHM>>
source§fn payload_mut(&mut self) -> &mut [u8] ⓘ
fn payload_mut(&mut self) -> &mut [u8] ⓘ
source§impl<B, PHM, const MAX_EXTENSIONS: usize> PayloadMut for DataBuffer<B, Ipv6Extensions<PHM, MAX_EXTENSIONS>>
impl<B, PHM, const MAX_EXTENSIONS: usize> PayloadMut for DataBuffer<B, Ipv6Extensions<PHM, MAX_EXTENSIONS>>
source§fn payload_mut(&mut self) -> &mut [u8] ⓘ
fn payload_mut(&mut self) -> &mut [u8] ⓘ
source§impl<B, PHM> PayloadMut for DataBuffer<B, Tcp<PHM>>
impl<B, PHM> PayloadMut for DataBuffer<B, Tcp<PHM>>
source§fn payload_mut(&mut self) -> &mut [u8] ⓘ
fn payload_mut(&mut self) -> &mut [u8] ⓘ
source§impl<B, PHM> PayloadMut for DataBuffer<B, Udp<PHM>>
impl<B, PHM> PayloadMut for DataBuffer<B, Udp<PHM>>
source§fn payload_mut(&mut self) -> &mut [u8] ⓘ
fn payload_mut(&mut self) -> &mut [u8] ⓘ
source§impl<B, HM> TcpMethods for DataBuffer<B, HM>where
B: AsRef<[u8]>,
HM: HeaderMetadata + HeaderMetadataMut + TcpMarker,
DataBuffer<B, HM>: PseudoHeaderChecksum,
impl<B, HM> TcpMethods for DataBuffer<B, HM>where
B: AsRef<[u8]>,
HM: HeaderMetadata + HeaderMetadataMut + TcpMarker,
DataBuffer<B, HM>: PseudoHeaderChecksum,
source§fn tcp_source_port(&self) -> u16
fn tcp_source_port(&self) -> u16
source§fn tcp_destination_port(&self) -> u16
fn tcp_destination_port(&self) -> u16
source§fn tcp_sequence_number(&self) -> u32
fn tcp_sequence_number(&self) -> u32
source§fn tcp_acknowledgment_number(&self) -> u32
fn tcp_acknowledgment_number(&self) -> u32
source§fn tcp_data_offset(&self) -> u8
fn tcp_data_offset(&self) -> u8
source§fn tcp_reserved_bits(&self) -> u8
fn tcp_reserved_bits(&self) -> u8
source§fn tcp_congestion_window_reduced_flag(&self) -> bool
fn tcp_congestion_window_reduced_flag(&self) -> bool
source§fn tcp_ecn_echo_flag(&self) -> bool
fn tcp_ecn_echo_flag(&self) -> bool
source§fn tcp_urgent_pointer_flag(&self) -> bool
fn tcp_urgent_pointer_flag(&self) -> bool
source§fn tcp_acknowledgement_flag(&self) -> bool
fn tcp_acknowledgement_flag(&self) -> bool
source§fn tcp_push_flag(&self) -> bool
fn tcp_push_flag(&self) -> bool
source§fn tcp_reset_flag(&self) -> bool
fn tcp_reset_flag(&self) -> bool
source§fn tcp_synchronize_flag(&self) -> bool
fn tcp_synchronize_flag(&self) -> bool
source§fn tcp_fin_flag(&self) -> bool
fn tcp_fin_flag(&self) -> bool
source§fn tcp_window_size(&self) -> u16
fn tcp_window_size(&self) -> u16
source§fn tcp_checksum(&self) -> u16
fn tcp_checksum(&self) -> u16
source§fn tcp_urgent_pointer(&self) -> u16
fn tcp_urgent_pointer(&self) -> u16
source§fn tcp_options(&self) -> Option<&[u8]>
fn tcp_options(&self) -> Option<&[u8]>
source§fn tcp_calculate_checksum(&self) -> u16
fn tcp_calculate_checksum(&self) -> u16
source§impl<B, HM> TcpMethodsMut for DataBuffer<B, HM>where
B: AsRef<[u8]> + AsMut<[u8]>,
HM: HeaderMetadata + HeaderMetadataMut + TcpMarker,
DataBuffer<B, HM>: PseudoHeaderChecksum + UpdateIpLength,
impl<B, HM> TcpMethodsMut for DataBuffer<B, HM>where
B: AsRef<[u8]> + AsMut<[u8]>,
HM: HeaderMetadata + HeaderMetadataMut + TcpMarker,
DataBuffer<B, HM>: PseudoHeaderChecksum + UpdateIpLength,
source§fn set_tcp_source_port(&mut self, port: u16)
fn set_tcp_source_port(&mut self, port: u16)
source§fn set_tcp_destination_port(&mut self, port: u16)
fn set_tcp_destination_port(&mut self, port: u16)
source§fn set_tcp_sequence_number(&mut self, sequence_number: u32)
fn set_tcp_sequence_number(&mut self, sequence_number: u32)
source§fn set_tcp_acknowledgement_number(&mut self, acknowledgement_number: u32)
fn set_tcp_acknowledgement_number(&mut self, acknowledgement_number: u32)
source§fn set_tcp_data_offset(
&mut self,
data_offset: u8
) -> Result<(), SetDataOffsetError>
fn set_tcp_data_offset( &mut self, data_offset: u8 ) -> Result<(), SetDataOffsetError>
source§fn set_tcp_reserved_bits(&mut self, reserved_bits: u8)
fn set_tcp_reserved_bits(&mut self, reserved_bits: u8)
source§fn set_tcp_flags(&mut self, flags: u8)
fn set_tcp_flags(&mut self, flags: u8)
source§fn set_tcp_congestion_window_reduced_flag(
&mut self,
congestion_window_reduced: bool
)
fn set_tcp_congestion_window_reduced_flag( &mut self, congestion_window_reduced: bool )
source§fn set_tcp_ecn_echo_flag(&mut self, ecn_echo: bool)
fn set_tcp_ecn_echo_flag(&mut self, ecn_echo: bool)
source§fn set_tcp_urgent_pointer_flag(&mut self, urgent_pointer: bool)
fn set_tcp_urgent_pointer_flag(&mut self, urgent_pointer: bool)
source§fn set_tcp_acknowledgement_flag(&mut self, acknowledgement: bool)
fn set_tcp_acknowledgement_flag(&mut self, acknowledgement: bool)
source§fn set_tcp_push_flag(&mut self, push: bool)
fn set_tcp_push_flag(&mut self, push: bool)
source§fn set_tcp_reset_flag(&mut self, reset: bool)
fn set_tcp_reset_flag(&mut self, reset: bool)
source§fn set_tcp_synchronize_flag(&mut self, synchronize: bool)
fn set_tcp_synchronize_flag(&mut self, synchronize: bool)
source§fn set_tcp_fin_flag(&mut self, fin: bool)
fn set_tcp_fin_flag(&mut self, fin: bool)
source§fn set_tcp_window_size(&mut self, window_size: u16)
fn set_tcp_window_size(&mut self, window_size: u16)
source§fn set_tcp_checksum(&mut self, checksum: u16)
fn set_tcp_checksum(&mut self, checksum: u16)
source§fn set_tcp_urgent_pointer(&mut self, urgent_pointer: u16)
fn set_tcp_urgent_pointer(&mut self, urgent_pointer: u16)
source§fn tcp_options_mut(&mut self) -> Option<&mut [u8]>
fn tcp_options_mut(&mut self) -> Option<&mut [u8]>
None
if no options are present.