[fix](ssl) fix ssl connection bug for JDBC 8.0.19 (#20659)

This commit is contained in:
abmdocrt
2023-06-11 13:50:03 +08:00
committed by GitHub
parent 987b29ded5
commit 3d9e520fb2

View File

@ -192,12 +192,6 @@ public class MysqlProto {
channel.setSslMode(true);
LOG.debug("switch to ssl mode.");
handshakeResponse = channel.fetchOnePacket();
capability = new MysqlCapability(MysqlProto.readLowestInt4(handshakeResponse));
if (!capability.isClientUseSsl()) {
ErrorReport.report(ErrorCode.ERR_NONSSL_HANDSHAKE_RESPONSE);
sendResponsePacket(context);
return false;
}
} else {
handshakeResponse = clientRequestPacket;
}