Kaynağa Gözat

Fix client SslStream certificate chain CRL validation. The logic was inverse and CRLs were never checked.

Add a missing dispose in managed client.
release/3.x.x
Craig Lutgen 5 yıl önce
ebeveyn
işleme
d7948afd98
2 değiştirilmiş dosya ile 2 ekleme ve 1 silme
  1. +1
    -0
      Source/MQTTnet.Extensions.ManagedClient/ManagedMqttClient.cs
  2. +1
    -1
      Source/MQTTnet/Implementations/MqttTcpChannel.cs

+ 1
- 0
Source/MQTTnet.Extensions.ManagedClient/ManagedMqttClient.cs Dosyayı Görüntüle

@@ -252,6 +252,7 @@ namespace MQTTnet.Extensions.ManagedClient
_maintainConnectionTask = null;
}

_messageQueueLock.Dispose();
_mqttClient.Dispose();
}



+ 1
- 1
Source/MQTTnet/Implementations/MqttTcpChannel.cs Dosyayı Görüntüle

@@ -86,7 +86,7 @@ namespace MQTTnet.Implementations
var sslStream = new SslStream(networkStream, false, InternalUserCertificateValidationCallback);
_stream = sslStream;

await sslStream.AuthenticateAsClientAsync(_options.Server, LoadCertificates(), _options.TlsOptions.SslProtocol, _options.TlsOptions.IgnoreCertificateRevocationErrors).ConfigureAwait(false);
await sslStream.AuthenticateAsClientAsync(_options.Server, LoadCertificates(), _options.TlsOptions.SslProtocol, !_options.TlsOptions.IgnoreCertificateRevocationErrors).ConfigureAwait(false);
}
else
{


Yükleniyor…
İptal
Kaydet