[Git][gajim/python-nbxmpp][master] Load files from FreeBSD specific location
Philipp Hörist
gitlab at dev.gajim.org
Fri Jul 20 23:50:08 CEST 2018
Philipp Hörist pushed to branch master at gajim / python-nbxmpp
Commits:
d713ce90 by Philipp Hörist at 2018-07-20T23:49:26+02:00
Load files from FreeBSD specific location
Fixes #53
- - - - -
1 changed file:
- nbxmpp/tls_nb.py
Changes:
=====================================
nbxmpp/tls_nb.py
=====================================
--- a/nbxmpp/tls_nb.py
+++ b/nbxmpp/tls_nb.py
@@ -448,12 +448,15 @@ class NonBlockingTLS(PlugIn):
store = tcpsock._sslContext.get_cert_store()
self._load_cert_file(self.cacerts, store)
self._load_cert_file(self.mycerts, store)
- if os.path.isdir('/etc/ssl/certs'):
- for f in os.listdir('/etc/ssl/certs'):
- # We don't logg because there is a lot a duplicated certs in this
- # folder
- self._load_cert_file(os.path.join('/etc/ssl/certs', f), store,
- logg=False)
+ paths = ['/etc/ssl/certs',
+ '/etc/ssl'] # FreeBSD uses this
+ for path in paths:
+ if not os.path.isdir(path):
+ continue
+ for f in os.listdir(path):
+ # We don't logg because there is a lot a duplicated certs
+ # in this folder
+ self._load_cert_file(os.path.join(path, f), store, logg=False)
tcpsock._sslObj = OpenSSL.SSL.Connection(tcpsock._sslContext,
tcpsock._sock)
View it on GitLab: https://dev.gajim.org/gajim/python-nbxmpp/commit/d713ce9059de350ce41f6d41f085d1c1a01742a4
--
View it on GitLab: https://dev.gajim.org/gajim/python-nbxmpp/commit/d713ce9059de350ce41f6d41f085d1c1a01742a4
You're receiving this email because of your account on dev.gajim.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gajim.org/pipermail/commits/attachments/20180720/f3268956/attachment-0001.html>
More information about the Commits
mailing list