简体   繁体   English

在Centos 7中PKIX路径构建失败

[英]PKIX path building failed in Centos 7

sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target; sun.security.validator.ValidatorException:PKIX路径构建失败:sun.security.provider.certpath.SunCertPathBuilderException:无法找到到请求目标的有效认证路径; nested exception is 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 嵌套的异常是javax.net.ssl.SSLHandshakeException:sun.security.validator.ValidatorException:PKIX路径构建失败:sun.security.provider.certpath.SunCertPathBuilderException:无法找到到请求目标的有效证书路径

Receiving following exception while triggering the SSL certified URL. 触发SSL认证的URL时收到以下异常。 Tried to fix the error by using following command 尝试使用以下命令修复错误

/opt/jdk1.8.0_51/jre/bin/keytool -import –alias -genkey –keystore “/opt/jdk1.8.0_51/jre/lib/security/cacerts” -file /apps/binlistlookup/src/main/resources/binlistnet.crt

The issue is still percieving in centos 7 system. centos 7系统中仍然存在该问题。

1 . 1。 keytool -genkey -keyalg RSA -alias selfsigned -keystore keystore.jks -storepass -validity 360 -keysize 2048

Some request will be shown asking your general datas. 系统会显示一些要求,询问您的一般数据。 Enter all of them. 输入所有这些。

2 . 2。 keytool -v -list -keystore keystore.jks

3 . 3。 keytool -exportcert -rfc -alias selfsigned -keystore keystore.jks -file selfsigned.crt

4 . 4。 keytool -printcert -file selfsigned.crt

Your cerfication file is ready. 您的认证文件已准备就绪。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM