MongoClientSettings.authenticateSSL
void authenticateSSL(string username, string sslPEMKeyFile, string sslCAFile = null) @safeSets ssl, the username, the PEM key file and the trusted CA file in this MongoClientSettings instance.
Parameters
username | The username as provided in the cert file like "C=IS,ST=Reykjavik,L=Reykjavik,O=MongoDB,OU=Drivers,CN=client". The username can be blank if connecting to MongoDB 3.4 or above. |
sslPEMKeyFile | Path to a certificate with private key and certificate chain to connect with. |
sslCAFile | Optional path to a trusted certificate authority file for verifying the remote certificate. |