当前位置:首页 > 开发 > 编程语言 > Web Service > 正文

cxf开发webservice生成数字安全证书

发表于: 2011-04-28   作者:bingyingao   来源:转载   浏览:
摘要: 分别生成服务端:serverStore.jks,clientStore.jks 1.创建一个私钥放入keystore里 keytool -genkey -alias apmclient -keypass apmclientpass  -keystore clientStore.jks - storepass keystorePass  -dname "cn=
分别生成服务端:serverStore.jks,clientStore.jks
1.创建一个私钥放入keystore里
keytool -genkey -alias apmclient -keypass apmclientpass  -keystore clientStore.jks -

storepass keystorePass  -dname "cn=nowwell" -keyalg RSA 
2.进行签名

keytool -selfcert -alias apmclient  -keystore clientStore.jks -storepass keystorePass

-keypass apmclientpass

3.导入私钥到key.rsa
keytool -export -alias apmclient  -file key.rsa -keystore clientStore.jks  -storepass

keystorePass

4.导入公钥到新的keystore中
keytool -import -alias apmserver -file key.rsa -keystore serverStore.jks -storepass

keystorePass  -keypass apmserverpass

客户端配置文件:
outsecurity_sign.properties
org.apache.ws.security.crypto.provider=org.apache.ws.security.components.crypto.Merlin
org.apache.ws.security.crypto.merlin.keystore.type=jks
org.apache.ws.security.crypto.merlin.keystore.password=keystorePass
#org.apache.ws.security.crypto.merlin.alias.password=apmclientpass
org.apache.ws.security.crypto.merlin.keystore.alias=apmclient
org.apache.ws.security.crypto.merlin.file=clientStore.jks

服务端配置文件:
server_insecurity_sign.properties
org.apache.ws.security.crypto.provider=org.apache.ws.security.components.crypto.Merlin
org.apache.ws.security.crypto.merlin.keystore.type=jks
org.apache.ws.security.crypto.merlin.keystore.password=keystorePass
#org.apache.ws.security.crypto.merlin.alias.password=keypass
org.apache.ws.security.crypto.merlin.keystore.alias=apmserver
org.apache.ws.security.crypto.merlin.file=serverStore.jks

cxf开发webservice生成数字安全证书

  • 0

    开心

    开心

  • 0

    板砖

    板砖

  • 0

    感动

    感动

  • 0

    有用

    有用

  • 0

    疑问

    疑问

  • 0

    难过

    难过

  • 0

    无聊

    无聊

  • 0

    震惊

    震惊

版权所有 IT知识库 CopyRight © 2009-2015 IT知识库 IT610.com , All Rights Reserved. 京ICP备09083238号