projectsend
projectsend copied to clipboard
Add configuration for MySQL SSL
Hi, I would like to set a path to the CA certificate for a self-signed SSL connection to the MySQL server.
Currently it requires a change in includes/database.php which won't survive updates, so I would like to potentially PR a new property in the config file, for ex. DB_MYSQL_SSL_CA. If this property is set, it would add to the existing PDO settings for MySQL these two additional properties:
PDO::MYSQL_ATTR_SSL_CA => DB_MYSQL_SSL_CA,
PDO::MYSQL_ATTR_SSL_VERIFY_SERVER_CERT => true
I'm not sure how you would do the same for MSSQL, so that's why I'd explicitly call the property DB_MYSQL_... so it's clear it's only supported there.
Would a PR with this change be okay?
Side note: the current database.php specifies PDO::MYSQL_ATTR_INIT_COMMAND for MSSQL, which I'm pretty sure won't work there.