标签:window ble security 导入失败 列表 dna 删除 csharp 商业
主要分为两大步:服务端生成配置证书,应用端导入证书。
keytool -genkey -keyalg RSA -alias mlongbosso -dname "cn=passport.mlongbo.com" -keystore /home/ndoc/test/cas/mlongbosso.keystore -storepass 123654
说明:指定使用RSA算法,生成别名为mlongbosso的证书,口令为123654,证书的DN为"cn=passport.mlongbo.com" ,这个DN必须同当前主机完整名称一致!!)
keytool -export -alias mlongbosso -file /home/ndoc/test/cas/mlongbosso.crt -keystore /home/ndoc/test/cas/mlongbosso.keystore -storepass 123654
(注释:从mlongbosso.keystore中导出别名为mlongbosso的证书,生成文件mlongbosso.crt)
3. 配置Tomcat的HTTPS服务
keystoreFile属性值为mlongbosso.keystore文件路径, keystorePass属性值为证书存贮口令
<Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true" maxThreads="150" scheme="https" secure="true" clientAuth="false" sslProtocol="TLS" keystoreFile="/home/ndoc/test/cas/mlongbosso.keystore" keystorePass="123654" />
应用端即SSO客户端.
注释: Windows下为%JAVA_HOME%
, Linux下为$JAVA_HOME
keytool -import -alias mlongbosso -file /home/ndoc/test/cas/mlongbosso.crt -keystore $JAVA_HOME/jre/lib/security/cacerts -storepass 123654
keytool -list -keystore $JAVA_HOME/jre/lib/security/cacerts -storepass 123654
注意:如果此处导入失败,或者要重新导入,需要先删除%JAVA_HOME%/jre/lib/security/cacerts
文件(删除前请备份)
转自:
作者:空谷幽兰
链接:http://www.jianshu.com/p/a1fa19d4ec75
來源:简书
著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。
标签:window ble security 导入失败 列表 dna 删除 csharp 商业
原文地址:http://www.cnblogs.com/winner2016/p/7930264.html