OpenSSL-Win32,rsa,私钥,公钥,1024,2048

默认是rsa_private_key1024.pem , PEM格式私钥,C# ,PHP 用。

再生成 pkcs8 格式私钥, JAVA 用。

公钥无格式区分。

1024 的:

openssl.exe genrsa -out rsa_private_key1024.pem 1024
openssl.exe pkcs8 -topk8 -inform PEM -in rsa_private_key1024.pem -outform pem -nocrypt -out rsa_private_key1024_pkcs8.pem
openssl.exe rsa -in rsa_private_key1024.pem -pubout -out rsa_public_key1024.pem
pause

2048的:

openssl.exe genrsa -out rsa_private_key2048.pem 2048
openssl.exe pkcs8 -topk8 -inform PEM -in rsa_private_key2048.pem -outform pem -nocrypt -out rsa_private_key2048_pkcs8.pem
openssl.exe rsa -in rsa_private_key2048.pem -pubout -out rsa_public_key2048.pem
pause

上一篇:1.2. chromium源代码分析 - chromiumframe - 入口函数


下一篇:并发编程 17—— Lock