SSL certificate error in Mongo

This is what I did exactly to establish an SSL connection.

1 Use openssl to generate client and server key (c.pem, s.pem)

2 Use openssl to generate client key request and server key request

3 Get a CA to sign both reqs and get certificates: c.cer, s.cer

4 concatenate c.pem and c.cer and get client.pem, similarly get server.pem

Now start the server:

mongod --sslMode requireSSL --sslPEMKeyFile server.pem -sslCAFile caroot.cer

start the client:

mongo --ssl --sslCAFile caroot.cer --sslPEMKeyFile client.pem

And now I am getting the error:

E NETWORK SSL peer certificate validation failed:certificate not trusted

Any thoughts on why this isn't working?

+3
ssl https mongodb


source to share


No one has answered this question yet

Check out similar questions:

381
Solution javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed Error?
106
How does SSL really work?
76
golang: How to make an https request with a bad certificate?
3
Generating a Certificate for Python Twisted SSL
2
Enable SSL in Mongo 3.0.5
1
MongoDB Self Signed SSL Connection: SSL peer certificate validation failed
0
SSL Certificate Verification
0
MongoDB SSL connection from Java application running in windows
-1
Valid SSL certificate issuing clear certificates



All Articles
Loading...
X
Show
Funny
Dev
Pics