kerryjiang / SuperSocket.ClientEngine

A .NET library which can make your socket client development easier
366 stars 197 forks source link

EasyClient not working with SSL #25

Closed sandvest closed 8 years ago

sandvest commented 8 years ago

Hi, The HostName in TcpClientSession is not set from EasyClientBase(was earlier set in constructor).

The function OnGetSocket(SocketAsyncEventArgs) in SslStreamTcpSession fails because the HostName is not set. ( sslStream.BeginAuthenticateAsClient(HostName, securityOption.Certificates, securityOption.EnabledSslProtocols, false, OnAuthenticated, sslStream); )

Atle

kerryjiang commented 8 years ago

Thanks for finding that.. I was aware of it but it still was missed :)

I'll try to fix it asap.

sandvest commented 8 years ago

Thanks, the AllowUnstrustedCertificate and NoDeplay must also be configurable from EasySocket if security is set to SSL/TLS.

kerryjiang commented 8 years ago

I made a serials of changes just now. Should cover what you said already.