Socket에다 SSL을 사용하는 Channel 클래스
Inheritance: Channel
Exemplo n.º 1
0
 public static SslChannel CreateChannel(Socket socket, string host)
 {
     var channel = new SslChannel(socket);
     channel._stream.AuthenticateAsClient(host);
     return channel;
 }
Exemplo n.º 2
0
 public static SslChannel CreateChannel(Socket socket, System.Security.Cryptography.X509Certificates.X509Certificate certificate)
 {
     var channel = new SslChannel(socket);
     channel._stream.AuthenticateAsServer(certificate);
     return channel;
 }