OpenVPN
|
Packet geometry parameters. More...
#include <mtu.h>
Data Fields | |
struct { | |
int payload_size | |
the maximum size that a payload that our buffers can hold from either tun device or network link. More... | |
int headroom | |
the headroom in the buffer, this is choosen to allow all potential header to be added before the packet More... | |
int tailroom | |
the tailroom in the buffer. More... | |
} | buf |
uint16_t | mss_fix |
The actual MSS value that should be written to the payload packets. More... | |
int | max_fragment_size |
The maximum size of a fragment. More... | |
int | tun_mtu |
the (user) configured tun-mtu. More... | |
int | tun_max_mtu |
the maximum tun-mtu size the buffers are are sized for. More... | |
int | extra_tun |
Maximum number of bytes in excess of the tun/tap MTU that might be read from or written to the virtual tun/tap network interface. More... | |
struct { ... } frame::buf |
Referenced by alloc_buf_sock_tun(), check_ping_send_dowork(), check_send_occ_msg_dowork(), do_data_channel_round_trip(), do_init_frame_tls(), encrypt_sign(), fragment_incoming(), fragment_outgoing(), fragment_ready_to_send(), frame_finalize_options(), frame_print(), init_frame_parameters(), openvpn_decrypt_aead(), openvpn_decrypt_v1(), process_outgoing_link(), process_outgoing_tun(), read_incoming_link(), read_incoming_tun(), test_crypto(), test_tls_crypt_secure_reneg_key(), tls_init_control_channel_frame_parameters(), tls_process(), and tls_reset_standalone().
int frame::extra_tun |
Maximum number of bytes in excess of the tun/tap MTU that might be read from or written to the virtual tun/tap network interface.
Only set with the option –tun-mtu-extra which defaults to 0 for tun and 32 (TAP_MTU_EXTRA_DEFAULT
) for tap.
Definition at line 145 of file mtu.h.
Referenced by do_init_frame(), frame_calculate_mssfix(), frame_calculate_payload_size(), and frame_print().
int frame::headroom |
the headroom in the buffer, this is choosen to allow all potential header to be added before the packet
Definition at line 108 of file mtu.h.
Referenced by alloc_buf_sock_tun(), check_ping_send_dowork(), check_send_occ_msg_dowork(), do_data_channel_round_trip(), encrypt_sign(), fragment_incoming(), fragment_outgoing(), fragment_ready_to_send(), frame_finalize_options(), frame_print(), init_frame_parameters(), init_tas_auth(), openvpn_decrypt_aead(), openvpn_decrypt_v1(), read_incoming_link(), read_incoming_tun(), test_crypto(), test_generate_reset_packet_plain(), tls_init_control_channel_frame_parameters(), tls_process(), and tls_reset_standalone().
int frame::max_fragment_size |
The maximum size of a fragment.
Fragmentation is done on the unencrypted payload after (potential) compression. So this value specifies the maximum payload size that can be send in a single fragment
Definition at line 124 of file mtu.h.
Referenced by fragment_outgoing(), frame_calculate_fragment(), and frame_print().
uint16_t frame::mss_fix |
The actual MSS value that should be written to the payload packets.
This is the value for IPv4 TCP packets. For IPv6 packets another 20 bytes must be subtracted
Definition at line 118 of file mtu.h.
Referenced by frame_calculate_mssfix(), frame_print(), multi_client_setup_dco_initial(), p2p_set_dco_keepalive(), and process_ip_header().
int frame::payload_size |
the maximum size that a payload that our buffers can hold from either tun device or network link.
Definition at line 102 of file mtu.h.
Referenced by alloc_buf_sock_tun(), check_ping_send_dowork(), check_send_occ_msg_dowork(), do_data_channel_round_trip(), do_init_frame_tls(), frame_finalize_options(), frame_print(), init_frame_parameters(), process_outgoing_link(), process_outgoing_tun(), read_incoming_tun(), test_crypto(), test_tls_crypt_secure_reneg_key(), and tls_init_control_channel_frame_parameters().
int frame::tailroom |
the tailroom in the buffer.
Chosen large enough to also accompany any extrea header or work space required by decryption/encryption or compression.
Definition at line 112 of file mtu.h.
Referenced by frame_finalize_options(), frame_print(), init_frame_parameters(), and tls_init_control_channel_frame_parameters().
int frame::tun_max_mtu |
the maximum tun-mtu size the buffers are are sized for.
This is the upper bound that a server can push as MTU
Definition at line 141 of file mtu.h.
Referenced by do_deferred_options(), do_init_frame_tls(), frame_finalize_options(), and frame_print().
int frame::tun_mtu |
the (user) configured tun-mtu.
This is used in configuring the tun interface or in calculations that use the desired size of the payload in the buffer.
This variable is also used in control frame context to set the desired maximum control frame payload (although most of code ignores it)
Definition at line 131 of file mtu.h.
Referenced by do_close_tun(), do_deferred_options(), do_open_tun(), frame_finalize_options(), frame_print(), init_frame_parameters(), ipv6_send_icmp_unreachable(), options_string(), and tls_init_control_channel_frame_parameters().