Merge pull request #101 from mi3z/mi3z_fix_ssl

TLS connections can be established by default with system certificate…
pull/8/head
Nicolas 2017-11-25 14:26:10 +01:00 zatwierdzone przez GitHub
commit 7bb40a96fc
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
1 zmienionych plików z 0 dodań i 3 usunięć

Wyświetl plik

@ -364,9 +364,6 @@ class MQTTClient:
self._handler = ClientProtocolHandler(self.plugins_manager, loop=self._loop)
if secure:
if self.session.cafile is None or self.session.cafile == '':
self.logger.warning("TLS connection can't be estabilshed, no certificate file (.cert) given")
raise ClientException("TLS connection can't be estabilshed, no certificate file (.cert) given")
sc = ssl.create_default_context(
ssl.Purpose.SERVER_AUTH,
cafile=self.session.cafile,