--tls-crypt fixes
* Check return value of buf_init() (found by coverity)
* Use the TLS frame to determine the buffer size, as is done for the
reliability buffers used for tls-auth. (We previously incorrectly used
the TLS *plaintext* buffer size, which is bigger for typical setups
with tun-mtu <= 1500. Using the frame to calculate the size saves some
bytes for typical setups, and doesn't break setups with big tun-mtu.)
* More carefully handle errors in tls_crypt_wrap() - just drop the packet
instead of ASSERT()ing out (should not happen in the first place, but
this is a bit more friendly if it happens somehow anyway).
Signed-off-by: Steffan Karger <steffan@karger.me>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <
1479847286-17518-1-git-send-email-steffan@karger.me>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg13204.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>