|
@@ -84,9 +84,9 @@ namespace MQTTnet.Implementations |
|
|
if (_options.TlsOptions.UseTls) |
|
|
if (_options.TlsOptions.UseTls) |
|
|
{ |
|
|
{ |
|
|
var sslStream = new SslStream(networkStream, false, InternalUserCertificateValidationCallback); |
|
|
var sslStream = new SslStream(networkStream, false, InternalUserCertificateValidationCallback); |
|
|
await sslStream.AuthenticateAsClientAsync(_options.Server, LoadCertificates(), _options.TlsOptions.SslProtocol, _options.TlsOptions.IgnoreCertificateRevocationErrors).ConfigureAwait(false); |
|
|
|
|
|
|
|
|
|
|
|
_stream = sslStream; |
|
|
_stream = sslStream; |
|
|
|
|
|
|
|
|
|
|
|
await sslStream.AuthenticateAsClientAsync(_options.Server, LoadCertificates(), _options.TlsOptions.SslProtocol, _options.TlsOptions.IgnoreCertificateRevocationErrors).ConfigureAwait(false); |
|
|
} |
|
|
} |
|
|
else |
|
|
else |
|
|
{ |
|
|
{ |
|
|