Opened 11 years ago
Closed 11 years ago
#24816 closed enhancement (duplicate)
Add support for secure DB connections to PDO / mysqli
Reported by: | hypertextranch | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | |
Component: | Database | Keywords: | |
Focuses: | Cc: |
Description
With the advent of database as a service cloud providers like Amazon RDS, ClearDB, etc. it would be good to have the option of connecting to MySQL over SSL so database credentials are not sent in clear text over the internet.
SSL support for mysql_connect was added in #19324 however with the impending update (in 3.6?) to PDO / mysql_* for database connections #21663 we will no longer have this option. (By the way I'm not sure the MYSQL_CLIENT_SSL
flag in mysql_connect()
ever worked as there's nowhere to specify CA/key/cert file paths)
I propose we patch #21663 to construct SSL enabled DB connections with mysqli::ssl_set()
and PDO driver options flags when all of the following constants are defined:
DB_SSL_KEY
DB_SSL_CERT
DB_SSL_CA
References:
http://www.php.net/manual/en/mysqli.ssl-set.php
http://php.net/manual/en/ref.pdo-mysql.php
Replying to hypertextranch:
This won't be landing in 3.6. I'd recommend that this suggestion stay as part of that ticket for now.