驅動程序無法通過使用安全套接字層(SSL)加密與?SQL?Server?建立安全連接,錯誤:“The?server?selected?protocol?version?TLS10?is?not?accepted?by?client
驅動程序無法通過使用安全套接字層(SSL)加密與 SQL Server 建立安全連接。錯誤:“The server selected protocol version TLS10 is not accepted by client
[2022-09-07 11:45:35.517] [Druid-ConnectionPool-Create-5339735] [ERROR] com.alibaba.druid.pool.DruidDataSource - create connection SQLException, url: jdbc:sqlserver://172.16.6.88:1433;DatabaseName=testServer, errorCode 0, state 08S01 com.microsoft.sqlserver.jdbc.SQLServerException: 驅動程序無法通過使用安全套接字層(SSL)加密與 SQL Server 建立安全連接。錯誤:“The server selected protocol version TLS10 is not accepted by client preferences [TLS12]”。 ClientConnectionId:f227ddec-3901-482c-bd54-6752243f1724 at com.microsoft.sqlserver.jdbc.SQLServerConnection.terminate(SQLServerConnection.java:2998) at com.microsoft.sqlserver.jdbc.TDSChannel.enableSSL(IOBuffer.java:1884) at com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:2558) at com.microsoft.sqlserver.jdbc.SQLServerConnection.login(SQLServerConnection.java:2216) at com.microsoft.sqlserver.jdbc.SQLServerConnection.connectInternal(SQLServerConnection.java:2067) at com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:1204) at com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(SQLServerDriver.java:825) at com.alibaba.druid.pool.DruidAbstractDataSource.createPhysicalConnection(DruidAbstractDataSource.java:1558) at com.alibaba.druid.pool.DruidAbstractDataSource.createPhysicalConnection(DruidAbstractDataSource.java:1623) at com.alibaba.druid.pool.DruidDataSource$CreateConnectionThread.run(DruidDataSource.java:2468) Caused by: javax.net.ssl.SSLHandshakeException: The server selected protocol version TLS10 is not accepted by client preferences [TLS12] at sun.security.ssl.Alert.createSSLException(Alert.java:131) at sun.security.ssl.Alert.createSSLException(Alert.java:117) at sun.security.ssl.TransportContext.fatal(TransportContext.java:357) at sun.security.ssl.TransportContext.fatal(TransportContext.java:313) at sun.security.ssl.TransportContext.fatal(TransportContext.java:304) at sun.security.ssl.ServerHello$ServerHelloConsumer.onServerHello(ServerHello.java:946) at sun.security.ssl.ServerHello$ServerHelloConsumer.consume(ServerHello.java:873) at sun.security.ssl.SSLHandshake.consume(SSLHandshake.java:376) at sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:479) at sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:457) at sun.security.ssl.TransportContext.dispatch(TransportContext.java:200) at sun.security.ssl.SSLTransport.decode(SSLTransport.java:154) at sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1290) at sun.security.ssl.SSLSocketImpl.readHandshakeRecord(SSLSocketImpl.java:1199) at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:401) at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:373) at com.microsoft.sqlserver.jdbc.TDSChannel.enableSSL(IOBuffer.java:1802) ... 8 common frames omitted
2. 找到 jdk.tls.disabledAlgorithms 如果有TLSv1、TLSv1.1、3DES_EDE_CBC 刪除即可【使用管理員模式編輯】
C:\Program Files (x86)\Java\jdk1.8.0_291\jre\lib\security
也有說 jdk、jre都要改的,如果jdk里面改了沒用,把 jre目錄下也改了試試
到此這篇關于驅動程序無法通過使用安全套接字層(SSL)加密與 SQL Server 建立安全連接。錯誤:“The server selected protocol version TLS10 is not accepted by client的文章就介紹到這了,更多相關驅動程序無法通過使用安全套接字層加密內容請搜索腳本之家以前的文章或繼續(xù)瀏覽下面的相關文章希望大家以后多多支持腳本之家!
相關文章
數(shù)據(jù)庫觸發(fā)器DB2和SqlServer有哪些區(qū)別
大部分數(shù)據(jù)庫語句的基本語法是相同的,但具體到的每一種數(shù)據(jù)庫,又有些不一樣,例如觸發(fā)器,DB2和SQL Server兩種很大的不同。對數(shù)據(jù)庫觸發(fā)器DB2和SqlServer有哪些區(qū)別感興趣的朋友一起看看本文吧2015-11-11SQLServer存儲過程創(chuàng)建和修改的實現(xiàn)代碼
這篇文章主要介紹了SQLServer存儲過程創(chuàng)建和修改的實現(xiàn)代碼,需要的朋友可以參考下2017-05-05