The server selected protocol version TLS10 is not accepted by client preferences

从jdk8升级到jdk11后,连接SqlServer出现驱动程序无法通过使用安全套接字层(SSL)加密与 SQL Server 建立安全连接。错误:“The server selected protocol version TLS10 is not accepted by client preferences [TLS13, TLS12, TLS11]”。 ClientConnectionId:c8558f1d-a942-47fd-9598-79c745f21a50
The server selected protocol version TLS10 is not accepted by client preferences_第1张图片
解决办法修改 D:\jdk-11\conf\security\java.security中

jdk.tls.disabledAlgorithms=SSLv3, TLSv1, TLSv1.1, RC4, DES, MD5withRSA, \
    DH keySize < 1024, EC keySize < 224, 3DES_EDE_CBC, anon, NULL, \
    include jdk.disabled.namedCurves
# modify by wangxiaomin
jdk.tls.disabledAlgorithms=SSLv3, TLSv1.1, RC4, DES, MD5withRSA, \
    DH keySize < 1024, EC keySize < 224, 3DES_EDE_CBC, anon, NULL, \
    include jdk.disabled.namedCurves

主要是去掉了 TLSv1

你可能感兴趣的:(遇到的开发问题,java)