Remove &~ bit-clearing method in favor of defaults.
For some reason the OP_ALL & ~OP_NO_COMPRESSION method doesnt work, but it is late and the default is false anyways.bug/bundler_fix
parent
109fc5a834
commit
a8c55f23a7
|
@ -89,10 +89,8 @@ begin
|
|||
self.sslctx.ciphers = params.ssl_cipher
|
||||
end
|
||||
|
||||
if params.ssl_compression
|
||||
self.sslctx.options = self.sslctx.options & ~OpenSSL::SSL::OP_NO_COMPRESSION
|
||||
else
|
||||
self.sslctx.options = self.sslctx.options | OpenSSL::SSL::OP_NO_COMPRESSION
|
||||
if not params.ssl_compression
|
||||
self.sslctx.options |= OpenSSL::SSL::OP_NO_COMPRESSION
|
||||
end
|
||||
|
||||
# Set the verification callback
|
||||
|
|
|
@ -136,13 +136,10 @@ module Rex::Socket::SslTcpServer
|
|||
ctx = OpenSSL::SSL::SSLContext.new()
|
||||
ctx.key = key
|
||||
ctx.cert = cert
|
||||
|
||||
ctx.options = 0
|
||||
|
||||
# enable/disable the SSL/TLS-level compression
|
||||
if params.ssl_compression
|
||||
# ctx.options &= ~OpenSSL::SSL::OP_NO_COMPRESSION
|
||||
else
|
||||
ctx.options = OpenSSL::SSL::OP_ALL
|
||||
if not params.ssl_compression
|
||||
ctx.options |= OpenSSL::SSL::OP_NO_COMPRESSION
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue