Auto detect proxy.