Skip to Content

Configure Jump Server to use SSL for AWS RDS

How to configure Ezeelogin Jump Server to use SSL for AWS RDS database connection?


Overview: This article helps to configure Ezeelogin to use SSL for AWS RDS database connection.


Refer this article to set up AWS RDS.

Download certificates for using SSL in AWS RDS from here.

Step 1: Move the certificate file to /usr/local/etc/ezlogin/ and ensure that the permissions of the certificate file are correctly set.

root@gateway ~]# mv certificate-file.pem /usr/local/etc/ezlogin/

root@gateway ~]# chmod 644 /usr/local/etc/ezlogin/certificate-file.pem

Step 2: Try connecting RDS with SSL using the below command.

root@gateway ~]# mysql -h mysql–instance1.123456789012.us-east-1.rds.amazonaws.com --ssl-ca= /path_of_cert_file/certificate-file.pem -P 3306 -u mymasteruser -p --ssl-mode=VERIFY_IDENTITY

Step 3: Append below lines in /usr/local/etc/ezlogin/ez.conf file and specify the path of certificate to use SSL RDS with Ezeelogin.

root@gateway ~]# vim /usr/local/etc/ezlogin/ez.conf

mysql_encrypt yes
 
mysql_ssl_ca /usr/local/etc/ezlogin/certificate-file.pem

Step 4: Try accessing GUI and Ezeelogin shell to confirm if it's using RDS SSL.

For database error, run below commands on the gateway server.

root@gateway ~]# mysql -h mysql–instance1.123456789012.us-east-1.rds.amazonaws.com -u mymasteruser -p

[Enter password]

mysql > grant all on ezlogin_databasename.* to 'mysql_username'@'%' identified by 'password' with grant option;

mysql > grant all on ezlogin_databasename.* to 'mysql_username'@'%' identified by 'password';

mysql > grant all on ezlogin_databasename.* to 'ezlogin_database_username'@'%' identified by 'ezlogin_database_password';

mysql > flush privileges;

mysql > exit


Related Articles:

Configure Ezeelogin on AWS RDS

Install Master/Slave Ezeelogin with MySQL SSL

Can we use the same database instance for cluster setup?

How to Migrate Ezeelogin database to rds / remote SQL instance?