Added support for socks proxies