SSL协议的下载及编译使用

6 篇文章 0 订阅
2 篇文章 0 订阅


一:SSL协议的下载:

下载地址:http://www.openssl.org/source/

二:SSL协议编译

下载下来的文件是一个压缩包,解压出来,你是找不到一个文件来打开进行界面操作的。

需使用命令编译。

编译步骤 原文链接:http://blog.csdn.net/everandforever/article/details/6102781


VC2010步骤:

 

1. 安装 ActivePerl

     activePerl下载地址:http://www.activestate.com/activeperl


2. 从Windows开始菜单运行“Visual Studio Command Prompt (2010)”

 

3. 进入openssl目录,例如 D:\openssl-1.0.0c,执行以下命令:

D:\openssl-1.0.0c>perl Configure VC-WIN32 --prefix=D:\openssl-1.0.0c

 

D:\openssl-1.0.0c>ms\do_ms

 

D:\openssl-1.0.0c>nmake -f ms\nt.mak

 

4. 以上是将openssl编译为静态链接的lib文件。如需编译为dll,最后一个命令改成

D:\openssl-1.0.0c>nmake -f ms\ntdll.mak


三、使用openssl.exe将证书或秘钥转换成pem文件

原文链接:http://hi.baidu.com/yang_qi168/item/480304c542fd246489ad9e91

使用OpenSSL

1、将aps_developer_identity.cer转换成 aps_developer_identity.pem格式。

openssl > x509 -in aps_developer_identity.cer -inform DER -out aps_developer_identity.pem -outform PEM

2、将p12格式的私钥转换成pem

openssl> pkcs12 -nocerts -out key.pem -in key.p12

3、用certificate和the key 创建PKCS#12格式的文件。

openssl >pkcs12 -export -in aps_developer_identity.pem -inkey PushChat_Noenc.pem -certfile PushChat.certSigningRequest -name "aps_developer_identity" -out aps_developer_identity.p12

这样我们就得到了在.net应用程序中使用的证书文件:aps_developer_identity.p12。



  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值