javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake錯誤

javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake
這個錯誤網上很多帖子說是jdk版本問題, 我試了不管用

只需要在請求代碼前面加上

System.setProperty("https.protocols", "TLSv1");

這行代碼 完美解決

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章