-
Notifications
You must be signed in to change notification settings - Fork 550
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Updated README SSL documentation #1142
Conversation
README.md
Outdated
@@ -263,8 +262,9 @@ Setting any of the following options will enable an SSL connection, but only if | |||
your MySQL client library and server have been compiled with SSL support. | |||
MySQL client library defaults will be used for any parameters that are left out | |||
or set to nil. Relative paths are allowed, and may be required by managed | |||
hosting providers such as Heroku. Set `:sslverify => true` to require that the | |||
server presents a valid certificate. | |||
hosting providers such as Heroku. For MySQL versions > `5.7.11` do not use `:sslverify` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest to rephrase this in the positive, how about:
For MySQL versions 5.7.11 and higher, use
:ssl_mode
to prefer or require an SSL connection and certificate validation. For earlier versions of MySQL, use the:sslverify
boolean.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Off the top of my head, I don't recall the specific behavior if the user set :sslverify
when connecting to MySQL 8. Based on the deprecation and now removal of this option, I think the mysql2 gem should enforce migrating users to :ssl_mode by way of warnings and failing the connection.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright, changing it to sound more positive makes sense. Regarding the behaviour, I can open up an issue to track it.
Co-Authored-By: Aaron Stone <[email protected]>
Cherry-picked as bab4969, belated thank you for this PR! |
Updated the README to better reflect the update SSL options that Mysql supports for versions >= 5.7.11.
I was struggling with understanding the difference between
verify_ssl
andssl_mode
and felt that clarifying this in the README would help.