]> git.ipfire.org Git - thirdparty/openvpn.git/commit - src/openvpn/init.c
Add mtu paramter to --fragment and change fragment calculation
authorArne Schwabe <arne@rfc2549.org>
Sat, 12 Feb 2022 00:33:31 +0000 (01:33 +0100)
committerGert Doering <gert@greenie.muc.de>
Sun, 13 Feb 2022 08:16:49 +0000 (09:16 +0100)
commit0d969976a338471869957d78867329b74ecf8bea
treee0a37697162dcc5add57189b84cf7f31ead506b6
parent0d86da32695539a96848b96149484af41bba83c5
Add mtu paramter to --fragment and change fragment calculation

Instead relying on the link_mtu_dynamic field and its calculation
in the frame struct, add a new field max_fragment_size and add
a calculation of it similar to mssfix.

Also whenever mssfix value is calculated, we also want to calculate
the values for fragment as both options need to be calculated from
the real overhead.

Patch v2: Fix syntax in rst man page
Patch v5: fix segfault when get_ip_encap_overhead gets called early in
          init_instance and note that these calls will always be
          overwritten by NCP in tls_session_update_crypto_params

Signed-off-by: Arne Schwabe <arne@rfc2549.org>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <20220212003331.3483107-1-arne@rfc2549.org>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg23764.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
15 files changed:
Changes.rst
doc/man-sections/link-options.rst
src/openvpn/forward.c
src/openvpn/fragment.c
src/openvpn/init.c
src/openvpn/mss.c
src/openvpn/mss.h
src/openvpn/mtu.c
src/openvpn/mtu.h
src/openvpn/options.c
src/openvpn/options.h
src/openvpn/socket.c
src/openvpn/socket.h
src/openvpn/ssl.c
tests/unit_tests/openvpn/test_crypto.c