Skip to content

Commit 739f0f0

Browse files
Log the default location of trusted CA certificates when tlsTrustCertsFilePath is not specified (#429)
### Motivation Currently when `tlsTrustCertsFilePath` is not specified, default locations of CA certificates will be used. However, these paths are determined by the compile option when building OpenSSL and they are invisible to users. If the OS uses a different path, the TLS connection will fail with no helpful error message.
1 parent 37bdf5b commit 739f0f0

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

lib/ClientConnection.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
*/
1919
#include "ClientConnection.h"
2020

21+
#include <openssl/x509.h>
2122
#include <pulsar/MessageIdBuilder.h>
2223

2324
#include <boost/optional.hpp>
@@ -227,6 +228,7 @@ ClientConnection::ClientConnection(const std::string& logicalAddress, const std:
227228
}
228229
} else {
229230
ctx.set_default_verify_paths();
231+
LOG_INFO("Use " << X509_get_default_cert_file() << " as default CA path");
230232
}
231233
}
232234

0 commit comments

Comments
 (0)