@@ -270,16 +270,22 @@ authentication is used).
270
270
271
271
The client will use CA certificates to verify the broker's certificate.
272
272
The embedded OpenSSL library will look for CA certificates in ` /usr/lib/ssl/certs/ `
273
- or ` /usr/lib/ssl/cacert.pem ` . CA certificates are typically provided by the
274
- Linux distribution's ` ca-certificates ` package which needs to be installed
275
- through ` apt ` , ` yum ` , et.al.
273
+ or ` /usr/lib/ssl/cacert.pem ` .
274
+
275
+ On Linux, CA certificates are typically provided by the distribution's ` ca-certificates `
276
+ package which needs to be installed through ` apt ` , ` yum ` , et.al.
277
+
278
+ On MacOS, different versions can store CA certificates in different locations.
279
+ On MacOS Mojave and later, for instance, this is usually ` '/private/etc/ssl/cert.pem' ` .
276
280
277
281
If your system stores CA certificates in another location you will need to
278
282
configure the client with ` 'ssl.ca.location': '/path/to/cacert.pem' ` .
279
283
280
- Alternatively, the CA certificates can be provided by the [ certifi] ( https://pypi.org/project/certifi/ )
281
- Python package. To use certifi, add an ` import certifi ` line and configure the
282
- client's CA location with ` 'ssl.ca.location': certifi.where() ` .
284
+ A more generic and fool-proof way to ensure SSL works is to install the
285
+ [ certifi] ( https://pypi.org/project/certifi/ ) Python package, which provides its own
286
+ bundled CA certificates, much like how Java works. To use certifi, install it, and then
287
+ add an ` import certifi ` line and configure the client's CA location with
288
+ ` 'ssl.ca.location': certifi.where() ` .
283
289
284
290
285
291
Prerequisites
0 commit comments