解决:Maven PKIX path building failed: sun.security.provider.certpath


在构建SpringBoot项目时,maven下载依赖会报 PKIX path building failed: sun.security.provider.certpath的错误。

使用https://blog.csdn.net/HuanglnQuan/article/details/104594117这篇文章的方法得以解决。

mvn clean && mvn compile -Dmaven.wagon.http.ssl.insecure=true -Dmaven.wagon.http.ssl.allowall=true -Dmaven.wagon.http.ssl.ignore.validity.dates=true

不过再使用命令时会出现新的错误

 Unknown lifecycle phase "&&". You must specify a valid lifecycle phase or a goal in the format <plu

去掉mvn clean &&,就成功开始下载依赖了......


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM