HttpGet with HTTPS : SSLPeerUnverifiedException

前端 未结 6 1680
旧时难觅i
旧时难觅i 2020-11-27 13:29

Using HttpClient, I receive the following error when attempting to communicate over HTTPS:

Exception in thread \"main\" javax.net.ssl.SSLPeerUnverifie

6条回答
  •  被撕碎了的回忆
    2020-11-27 14:07

    Your local JVM or remote server may not have the required ciphers. go here

    https://www.oracle.com/java/technologies/javase-jce8-downloads.html

    and download the zip file that contains: US_export_policy.jar and local_policy.jar

    replace the existing files (you need to find the existing path in your JVM).

    on a Mac, my path was here. /Library/Java/JavaVirtualMachines/jdk1.8.0_131.jdk/Contents/Home/jre/lib/security

    this worked for me.

提交回复
热议问题