Bad handshake when user SSH Tunnel with SSL

Jelmer posted 1 month ago in Creating a connection

Hi there,

When I make a connection to a server using SSH Tunnel and SSL, I get the error "Bad Handshake". A connection to the same server can be made directly with SSL, or through a SSH Tunnel without SSL.

Also, it is not possible to change the SSL checkbox when the connection type is SSH Tunnel.

We usualy use direct access using SSL for an elevated user. Only when we need root access (i.e. when working with permissions and users) we use SSH tunnel and "localhost" access for root. Allthough the tunnel itself will be encrypted, the local connection between SSH and Mariadb will not, and can be snooped, for example by a user script on a shared hosting server.

Any idea what could be wrong? I tried all available mysql.dll versions...

Regards, Jelmer

cBell posted 2 weeks ago

I am experiencing a similar, if not same problem. This is an existing connection that worked fine ~20 days ago, but now I get the "Bad Handshake" error. It is using an SSH tunnel and require_secure_transport = ON. If I run plink.exe separately with the same arguments that HeidiSQL is using and then create a new "local" connection that connects to localhost over the port being redirected with plink, it works fine as long as the "Use SSL" checkbox is checked. Mysql error log isn't much help. Every time I connect, I get:

2019-03-04T18:55:45.614892Z 1016213 [Note] Got timeout reading communication packets
2019-03-04T18:55:45.614964Z 1016214 [Note] Got timeout reading communication packets
2019-03-04T18:55:57.507653Z 1016218 [Note] Got timeout reading communication packets
2019-03-04T18:55:57.507701Z 1016219 [Note] Got timeout reading communication packets
2019-03-04T18:55:57.507816Z 1016224 [Note] Got timeout reading communication packets
2019-03-04T18:55:57.509848Z 1016220 [Note] Got timeout reading communication packets
2019-03-04T18:55:57.510792Z 1016222 [Note] Got timeout reading communication packets
2019-03-04T18:55:57.510822Z 1016223 [Note] Got timeout reading communication packets
2019-03-04T18:55:57.510800Z 1016221 [Note] Got timeout reading communication packets
2019-03-04T18:56:02.688560Z 1016226 [Note] Bad handshake
cBell posted 2 weeks ago

I should also probably mention I upgraded MySQL about 12 days ago to Ver 14.14 Distrib 5.7.25. It's entirely possible this is related to the upgrade, as I may not have tried to connect until today.

Please login to leave a reply, or register at first.