Disable SSL compression
PATCH 1/1 Disable SSL compression
As reported in trac #502, SSL compression can cause problems in some corner cases. OpenVPN does not need SSL compression, since the control channel is low bandwidth. This does not influence the data channel compressen (i.e. --comp or --comp-lzo).
Even though this has not yet been relevant for OpenVPN (since an attacker can not easily control contents of control channel messages), SSL compression has been used in the CRIME and BREACH attacks on TLS. TLS 1.3 will probably even remove support for compression all together, for exactly this reason.
Since we don't need it, and SSL compression causes issues, let's just disable it in OpenSSL builds. PolarSSL has no run-time flag to disable compression, but is by default compiled without compression.
--- src/openvpn/ssl_openssl.c | 4 ++++ 1 file changed, 4 insertions(+)
src/openvpn/ssl_openssl.c +4 -0
@@ -203,6 +203,10 @@ tls_ctx_set_options (struct tls_root_ctx *ctx, unsigned int ssl_flags)if (tls_ver_min >TLS_VER_1_2 || tls_ver_max <TLS_VER_1_2 ) sslopt |= SSL_OP_NO_TLSv1_2;#endif +#ifdef SSL_OP_NO_COMPRESSION +/* Disable compression - flag not available in OpenSSL 0.9.8 */ + sslopt |=SSL_OP_NO_COMPRESSION ; +#endif SSL_CTX_set_options (ctx->ctx, sslopt); }
Signature · 1 line
2.1.0
Quoted 11 lines · Steffan Karger
As reported in trac #502, SSL compression can cause problems in some corner cases. OpenVPN does not need SSL compression, since the control channel is low bandwidth. This does not influence the data channel compressen (i.e. --comp or --comp-lzo).
Even though this has not yet been relevant for OpenVPN (since an attacker can not easily control contents of control channel messages), SSL compression has been used in the CRIME and BREACH attacks on TLS. TLS 1.3 will probably even remove support for compression all together, for exactly this reason.
Quoted 4 lines
Since we don't need it, and SSL compression causes issues, let's just disable it in OpenSSL builds. PolarSSL has no run-time flag to disable compression, but is by default compiled without compression.
ACK from me. Sounds sensible to me. If do not support 0.9.8 anymore (in -master perhaps?) I would like this to be commited without ifdef.
Arne
Quoted 2 lines · Arne Schwabe
ACK from me. Sounds sensible to me. If do not support 0.9.8 anymore (in -master perhaps?) I would like this to be commited without ifdef.
Agreed, but we went from 0.9.6+ in 2.3 to 0.9.8+ in 2.4/master.
I put 0.9.8 explicitly in the comment, so that if we decide to drop support for 0.9.8, it is easy to spot that we can remove these ifdefs. (and if we drop 0.9.8, we can probably remove a lot more code :) ).
-Steffan
ACKmetoo.
Your patch has been applied to the master and release/2.3 branch.
commit 5d5233778868ddd568140c394adfcfc8e3453245 (master) commit 5b46cf43432e69bb55747830494f613115a2af0c (release/2.3)
Author: Steffan Karger Date: Sun Feb 15 15:24:26 2015 +0100
Disable SSL compression
Signed-off-by: Steffan Karger <[email protected]...>
Acked-by: Arne Schwabe <[email protected]...>
Acked-by: Gert Doering <[email protected]...>
Message-Id: <[email protected]...>
URL: http://article.gmane.org/gmane.network.openvpn.devel/9453
Signed-off-by: Gert Doering <[email protected]...>--
kind regards,
Gert Doering
Quoted 12 lines · Arne Schwabe
Quoted 11 lines · Steffan Karger
As reported in trac #502, SSL compression can cause problems in some corner cases. OpenVPN does not need SSL compression, since the control channel is low bandwidth. This does not influence the data channel compressen (i.e. --comp or --comp-lzo).
Even though this has not yet been relevant for OpenVPN (since an attacker can not easily control contents of control channel messages), SSL compression has been used in the CRIME and BREACH attacks on TLS. TLS 1.3 will probably even remove support for compression all together, for exactly this reason.
Quoted 6 lines
Quoted 4 lines
Since we don't need it, and SSL compression causes issues, let's just disable it in OpenSSL builds. PolarSSL has no run-time flag to disable compression, but is by default compiled without compression.
ACK from me. Sounds sensible to me. If do not support 0.9.8 anymore (in -master perhaps?) I would like this to be commited without ifdef.
We've agreed to support RHEL5 until it goes EOL, which is March 31, 2017. [1] As RHEL5 is on 0.9.8 we need to support it. RHEL6 is on 1.0.1, so we'll have something to look forward too ;-)
[1] There is also an additional "extended life cycle" which RHEL customers may opt-in for (for an additional fee), which I don't think we should relate too.
<https://access.redhat.com/support/policy/updates/errata>
Signature · 3 lines
kind regards, David Sommerseth