HANDSHAKE_SSL_ERROR : self signed certificate in certificate chain

Posted May 9, 2021 290 views

In a login page I have pointing to a managed MySQL database hosted in Digital Ocean, I get the following message in Chrome’s dev tools:

Error: self signed certificate in certificate chain
at TLSSocket.<anonymous> (/opt/nodeapp/nodemodules/mysql2/lib/connection.js:342:54)
at TLSSocket.emit (events.js:315:20)
at TLSSocket.finishInit (tlswrap.js:932:8)
at TLSWrap.ssl.onhandshakedone (

I think I have the certificates correctly. Please advise what I may be doing wrong.

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
1 answer

Hi there,

Do you have the path to the CA certificate specified in your MySQL connection string? Also, could you share the connection string details that you are using here? Make sure to remove any sensitive information from there before sharing it here.