1

我正在使用 play-framework 开发 Sbt 项目,并在 Build.sbt 文件中添加了以下 gluu-oxd 依赖项:

resolvers += "Gluu repository" at "http://ox.gluu.org/maven"
libraryDependencies += "org.xdi" % "oxd-java" % "2.4.4.Final"
libraryDependencies += "oxd.play.java" % "oxd-play" % "2.4.4-FINAL"
libraryDependencies += "org.xdi" % "oxd" % "2.4.4.Final"

参考:https ://gluu.org/docs/oxd/2.4.4/framework/play/

现在我在编译项目时遇到以下问题:

   [warn]  :: oxd.play.java#oxd-play;2.4.4-FINAL: Gluu repository: unable to get resource for oxd/play/java#oxd-play;2.4.4-FINAL: res=http://ox.gluu.org/maven/oxd/play/jav
    a/oxd-play/2.4.4-FINAL/oxd-play-2.4.4-FINAL.pom:
    [warn]  :: org.xdi#oxd;2.4.4.Final: Gluu repository: unable to get resource for org/xdi#oxd;2.4.4.Final: res=http://ox.gluu.org/maven/org/xdi/oxd/2.4.4.Final/oxd-2.4.4.
    Final.pom: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderE
    xception: unable to find valid certification path to requested target
    [warn]  ::::::::::::::::::::::::::::::::::::::::::::::
    [warn]  Note: Unresolved dependencies path:
    [warn]          org.xdi:oxd-java:2.4.4.Final (F:\Project\Master\OxdTest\build.sbt#L9-10)
    [warn]            +- default:oxdtest_2.12:0.1
    [warn]          oxd.play.java:oxd-play:2.4.4-FINAL (F:\Project\Master\OxdTest\build.sbt#L10-11)
    [warn]            +- default:oxdtest_2.12:0.1
    [warn]          org.xdi:oxd:2.4.4.Final (F:\Project\Master\OxdTest\build.sbt#L11-12)
    [warn]            +- default:oxdtest_2.12:0.1
    [error] sbt.librarymanagement.ResolveException: unresolved dependency: org.xdi#oxd-java;2.4.4.Final: Gluu repository: unable to get resource for org/xdi#oxd-java;2.4.4.
4

1 回答 1

0

直接问题似乎是错误消息“PKIX 路径构建失败:sun.security.provider.certpath.SunCertPathBuilderException:无法找到请求目标的有效证书路径”中的内容。换句话说,JVM 不信任https://ox.gluu.org/maven/提供的 SSL 证书,其根 CA 似乎是“DST Root CA X3”。

如果您没有使用最新的 OpenJDK JDK8 或 Oracle JDK 8,那么尝试这些可能是一个好的开始。

于 2018-12-17T00:05:10.477 回答