This project is archived and is in readonly mode.
MySQL SSL settings do not always require the sslkey option
Reported by Micah Wedemeyer | May 25th, 2008 @ 09:58 PM
Using the MySQL SSL settings in database.yml is conditional on there being an 'sslkey' option set. While this is sometimes the case, it's not always necessary. In many cases the only required option to set is the 'sslca' (certificate authority) file. This file is always required, even when the 'sslkey' option is also set.
Taken straight from the MySQL docs at: http://dev.mysql.com/doc/refman/...
If the account has no special SSL requirements or was created using a GRANT statement that includes the REQUIRE SSL option, a client can connect securely by using just the --ssl-ca option:
The patch just changes the conditional to check if 'sslca' is set instead of looking for 'sslkey'.
I have tested this on my local setup using only the sslca option. The connection worked fine and was being encrypted correctly (ie. I could see the SSL cipher when running the command 'SHOW STATUS LIKE 'Ssl_cipher';')
I apologize if the git patch is not correctly formatted. This is my first experience with git.
Comments and changes to this ticket
-
Pratik May 25th, 2008 @ 10:38 PM
- Title changed from [PATCH] MySQL SSL settings do not always require the sslkey option to MySQL SSL settings do not always require the sslkey option
-
Micah Wedemeyer May 25th, 2008 @ 11:00 PM
I forgot to update the comments to add the sslca option. It's actually been in the code for a while, but never made it into the comments.
Attaching a patch with the updated comments.
-
Repository July 12th, 2008 @ 03:01 AM
- State changed from new to resolved
- Tag set to activerecord, patch, ssl
(from [5e2e1ed9ffc481a91596d8c3fd9a68d7977e75ca]) Ensure MysqlAdapter allows SSL connection when only sslca is supplied. [#253 state:resolved]
Signed-off-by: Pratik Naik
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>