question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Should check server SSL capability

See original GitHub issue

It is also MySQL 5.6 compatibility problem for #32 .

MySQL 5.6.x Community Edition does not support SSL, so if the user has enabled SSL and the MySQL server is 5.6.x Community Edition, the user will receive an error message containing a handshake failure.

In this case, checking the MySQL server capabilities in HandshakeV10Message will be more useful than checking the MySQL server version.

My personal opinion is that for MySQL, SSL cannot support only enable/disable, and should support the following 3 modes:

  • REQUIRED (high security): if server not support SSL, then throw a exception to channel (connection will be close by this exception)
  • OPTIONAL (default mode): if server not support SSL, then disable SSL.
  • DISABLED (plain mode): use plain connection without SSL.

R2DBC ConnectionFactoryOptions.SSL is a boolean option, I try treat true same as OPTIONAL, and append a SSL option Option.<Boolean>valueOf("sslRequired") for enable REQUIRED mode.

@mp911de Should I support optional SSL mode for MySQL 5.6 compatibility?

Another plan is just throw an exception and close the connection when the user has enabled SSL and the MySQL server does not support SSL. Then r2dbc-mysql still only has two modes, ENABLED or DISABLED. (Equivalent to ENABLED same as REQUIRED, and the OPTIONAL mode is removed)

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
mp911decommented, Jul 20, 2019

Not setting SSL to true means SSL config is undefined. We had a similar discussion at https://github.com/r2dbc/r2dbc-postgresql/pull/104

0reactions
mirromutthcommented, Jul 28, 2019

SSL_MODE has supported yet, and single flag SSL would been keep.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How To Check SSL Certificates and Stay Secure - Keyfactor
You can easily find out whether your connection is secure by checking for the SSL certificate issued by the website you are trying...
Read more >
How to verify that SSL for IMAP/POP3/SMTP works and a ...
Any Linux server can be used for these tests. If you do not have a Linux server, use the online checkers above. To...
Read more >
What Is SSL Server Certificate and How Does It Protect ...
An SSL server certificate is a digital certificate issued to the server for two main purposes – to authenticate the server's identity and...
Read more >
Projects / SSL Client Test: Qualys SSL Labs
SSL /TLS Capabilities of Your Browser ... To test manually, click here. ... This really means that you should upgrade your software to...
Read more >
What is an SSL Certificate? - DigiCert.com
All browsers have the capability to interact with secured web servers using the SSL protocol. However, the browser and the server need what...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found