Allow SSL Connection over SOCKS Proxy

Currently SSL connection is not enabled if a SOCKS Proxy is set.
This allows to connect to the server over SSL over SOCKS Proxy.