trying to use certs for securing connections between Tomcat 8.x and mysql/mariadb. I'm going to use a self-signed cert. What follows is what i think i should be going and appreciate you to jump in and correct me.
Create Backend(DB) certs
- sudo openssl genrsa 4096 > ca-key.pem
- sudo openssl req -new -x509 -nodes -days 3600 -key ca-key.pem -out ca-cert.pem
- sudo openssl req -newkey rsa:4096 -days 3600 -nodes -keyout server-key.pem -out server-req.pem
- sudo openssl rsa -in server-key.pem -out server-key.pem
- sudo openssl x509 -req -in server-req.pem -days 3600 -CA ca-cert.pem -CAkey ca-key.pem -set_serial 01 -out server-cert.pem
update the mysql cnf
Ok, here's where i don't know how to proceed. I think i have to use the JAVA keytool .
Where do i go from here ?