我正在将我们的平台迁移到 JDK 11,其中一项服务在调用 graph.facebook.com API 时出现以下问题:
org.springframework.web.client.ResourceAccessException: I/O error on GET request for "https://graph.facebook.com/v3.1/xxxxx/adaccounts": peer not authenticated; nested exception is javax.net.ssl.SSLPeerUnverifiedException: peer not authenticated... Caused by: javax.net.ssl.SSLPeerUnverifiedException: peer not authenticated
我已经检查了机器上的 ca-certs,一切看起来都很好:
ca-certificates is already the newest version (20180409). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
最佳答案
您可以尝试将 OpenJDK 更新到 11.0.3 或更高版本。
我最近有一个 SSLPeerUnverifiedException
偶尔出现在 11.0.2 的应用程序中,同时偶尔出现 SSLException: No PSK available。无法恢复。
失败。后者似乎来自 known bug在 JDK 11.0.2 中。当我更新到 11.0.4 时,这两个问题都消失了。
关于java - JDK 11.javax.net.ssl.SSLPeerUnverifiedException : peer not authenticated,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55128398/