Catch bad SSL config

This commit is contained in:
James Cole
2020-09-05 07:37:18 +02:00
parent d809b77154
commit 366744ed69

View File

@@ -50,7 +50,8 @@ $mysql_ssl_ciphers = envNonEmpty('MYSQL_SSL_CIPHER', null);
$mysql_ssl_verify = envNonEmpty('MYSQL_SSL_VERIFY_SERVER_CERT', null);
$mySqlSSLOptions = [];
if (false !== envNonEmpty('MYSQL_USE_SSL', false)) {
$useSSL = envNonEmpty('MYSQL_USE_SSL', false);
if (false !== $useSSL && null !== $useSSL) {
if (null !== $mysql_ssl_ca_dir) {
$mySqlSSLOptions[PDO::MYSQL_ATTR_SSL_CAPATH] = $mysql_ssl_ca_dir;
}