0
我試圖使用Apache Commons VFS從http://openexchangerates.org API獲取數據。我收到的錯誤意味着它試圖使用SSL驗證 - 而不是我通過我的網站計劃提供的東西。有沒有辦法可以'強制'VFS使用http而不是https?阻止Apache Commons VFS嘗試使用SSL
巨大的堆棧跟蹤的相關要點如下包括 - 如果需要,可以提供更多的信息:
org.apache.commons.vfs2.VFS.getManager().resolveFile("http://openexchangerates.org/api/latest.json?api_id=MY_APP_ID")
org.apache.commons.vfs2.FileSystemException: Could not connect to HTTP server on "openexchangerates.org".
Caused by: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
Caused by: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
感謝您的解釋! – Serenthia