-
Type:
Task
-
Resolution: Done
-
Priority:
Major - P3
-
None
-
Affects Version/s: 2.4.4, 2.5
-
Component/s: Connectivity
-
Environment:ASP.NET core 2.0
microsoft/aspnetcore:2.0 docker container
-
None
-
None
-
None
-
None
-
None
-
None
-
None
When trying to connect to a MongoDB replica set via TLS I'm getting a RemoteCertificateNameMismatch error. This only happens when running in the docker container (not sure if it's a Linux thing or just Docker) and runs absolutely fine on Windows.
The Subject of the certificate looks like:
C=US, O=MongoDirector.com., CN=*.servers.mongodirector.com
The connection string looks similar to:
mongodb://SG-rsname-8081.servers.mongodirector.com:27017,SG-rsname-8082.servers.mongodirector.com:27017/supervisor-dev?replicaSet=RS-rsname-0&ssl=true
I thought maybe it was a .NET core issue on Linux. But I created a simple http call to a URI that also uses a wildcard certificate and it worked fine.