maven - 如何修复: Host name 'repo1.maven.org' does not match the certificate subject provided

标签 maven gradle certificate hostname repo

我的构建今天开始失败。看起来我们仍然指向一个已弃用的 Maven 存储库?如何更新我的 gradle 构建而不必覆盖每个 mavenCentral?!

如果我执行以下操作,那么我的构建将再次正常工作。但我有很多项目需要在 Jenkins 中构建。

repositories{
    mavenCentral(url:'https://repo.maven.apache.org/maven2')
}

这是我们看到的错误:

> Could not resolve commons-lang:commons-lang:2.6.
  Required by:
      project : > [ snip ]:1.0-SNAPSHOT > net.sf.ezmorph:ezmorph:1.0.6
   > Could not resolve commons-lang:commons-lang:2.6.
      > Could not get resource 'https://repo1.maven.org/maven2/commons-lang/commons-lang/2.6/commons-lang-2.6.pom'.
         > Could not GET 'https://repo1.maven.org/maven2/commons-lang/commons-lang/2.6/commons-lang-2.6.pom'.
            > Host name 'repo1.maven.org' does not match the certificate subject provided by the peer (CN=repo.maven.apache.org, O="Sonatype, Inc", L=Fulton, ST=MD, C=US)

TIA!

皮科

最佳答案

这是今天开始的问题,请使用 https://issues.sonatype.org/browse/MVNCENTRAL-2870用于跟踪状态。

关于maven - 如何修复: Host name 'repo1.maven.org' does not match the certificate subject provided,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47274255/

相关文章:

java - 如何通过 Maven 将额外的自定义类路径条目添加到 Spring Boot 运行中?

java - Persistence.xml 在正确的文件夹中,但我仍然收到错误

android - Gradle 无法解析 : com. firebaseui :firebase-ui-auth:3. 2.1

Java程序需要根证书吗?

android - 重新签署 Android Apk

c# - 如何检查 SqlConnection 中使用的 SQL Server 端 SSL 证书?

java - 使用 Maven 导出 .jar 时出现 NoClassDefFoundError

java - c3p0 - 不同服务器的连接池查询

java - 如何在maven的settings.xml中配置无代理?

android - Gradle 多项目 android 库设置与 maven 本地