Om Naidu
Om Naidu

Reputation: 11

How to setup AWS rds with SSL with phpmyadmin

I want to encrypt the connection to db from phpmyadmin using SSL. I am confused on how to use bundle certificate

Upvotes: 0

Views: 1159

Answers (3)

Md Shahbaz Ahmad
Md Shahbaz Ahmad

Reputation: 365

First you have to download the certificate by visiting here: Download an SSL certificate for your managed database in Amazon Lightsail

Here is a direct link for combined ca bundle: rds-combined-ca-bundle.pem

Now copy this 'rds-combined-ca-bundle.pem' file to your phpMyAdmin folder and search for config.inc.php file.

open this file (config.inc.php) in notepad or in any text editor and write the below lines:

$cfg['Servers'][$i]['ssl'] = true;
$cfg['Servers'][$i]['ssl_ca'] = 'rds-combined-ca-bundle.pem';
$cfg['Servers'][$i]['ssl_mode'] = 'VERIFY_IDENTITY';

Now save the file and visit you host (http://localhost/phpMyAdmin).

enter image description here

Update: You may download the Global Bundle which has all of the certificates including the new rds-ca-rsa2048-g1

Upvotes: 1

Marcin
Marcin

Reputation: 238319

You have to set it up as described in the docs using $cfg['Servers'][$i]['ssl'] option:

Whether to enable SSL for the connection between phpMyAdmin and the MySQL server to secure the connection.

Upvotes: 0

Joe K
Joe K

Reputation: 1

This worked for me:

Upload the rds-combined-ca-bundle.pem to some path that phpMyAdmin can access.

Then set the following configuration vars in config.inc.php:

$cfg['Servers'][$i]['ssl_ca_path'] = '/path/to/';
$cfg['Servers'][$i]['ssl_key'] = 'rds-combined-ca-bundle.pem';
$cfg['Servers'][$i]['ssl_cert'] = 'rds-combined-ca-bundle.pem';
$cfg['Servers'][$i]['ssl_ca'] = '/path/to/rds-combined-ca-bundle.pem';

Upvotes: 0

Related Questions