andyedinborough / aenetmail

C# POP/IMAP Mail Client
369 stars 153 forks source link

Timeout connect enhacement timeout #60

Open fujiyamatlenpl opened 12 years ago

fujiyamatlenpl commented 12 years ago

Hi, I've succesfully tested an enhancement in Connect method. I had an issue with slow responding IMAP server during auth process so I added timeout parameters in connect method before invocation of AuthenticateAsClient method. Please consider include some solution in a code. Best regards!

example:

sslStream.ReadTimeout = sslStream.WriteTimeout=connectionTimout; sslStream.AuthenticateAsClient(hostname);

0000day commented 7 years ago

This is still a problem. The existing timeout-properties aren't covering the connection itself. I've got the case that a provider blocked my IP because of too many failed tryouts. In this case the next connect-attempt takes something about 10-20 seconds.

This has to be able to set.