Set connection timeouts for HTTPS proxy attempts.

 Fixes #2336