added TLS support for Client sockets