add socket connect timeout and recv timeout

I'm thinking that perhaps a longer timeout (10 seconds?) or a configurable timeout parameter would be a good idea. If you're trying to query a particularly unreliable / poorly maintained WHOIS server, you could easily hit a 5 second connection timeout even if the server is up. What are your thoughts on this?