$ssl['cert'
] ?? null,
$ssl['ca'
] ?? null,
$ssl['capath'
] ?? null,
$ssl['cipher'
] ?? null
);
} $clientFlags += MYSQLI_CLIENT_SSL;
} try { if ($this->mysqli->
real_connect( $hostname,
$this->username,
$this->password,
$this->database,
$port,
$socket,
$clientFlags )) { // Prior to version 5.7.3, MySQL silently downgrades to an unencrypted connection if SSL setup fails
if (($clientFlags & MYSQLI_CLIENT_SSL
) &&
version_compare($this->mysqli->client_info, 'mysqlnd 5.7.3', '<='
) &&
empty($this->mysqli->
query("SHOW STATUS LIKE 'ssl_cipher'"
)->
fetch_object()->Value
) )