unable to find valid certification path to requested target 解决方法
使用gradle构建的时候无法从aliyun的镜像库下载相应的jar包提示这个错误:
unable to find valid certification path to requested target
这里的意思是,无法找到请求目标的有效证书路径。
解决方法:
到对应的网站将证书复制到本地,将证书加入%JAVA_HOME%\jre\lib\security 下的证书库 cacerts中
使用cmd:
keytool -import -trustcacerts -alias aliyun -keystore "%JAVA_HOME%\jre\lib\security\cacerts" -file "证书的路径" -storepass changeit

浙公网安备 33010602011771号