简体   繁体   English

Openssl Public\\Private key 跨操作系统平台支持

[英]Openssl Public\Private key Cross OS Platform Support

Question 1) Can we use the public/Private keys generated on One Operating system (Linux) to Another Operating system (MacOS or Windows)?问题 1) 我们可以将在一个操作系统 (Linux) 上生成的公钥/私钥用于另一个操作系统 (MacOS 或 Windows) 吗?

Question 2) Does having different version of OpenSSL on different operating system will cause any issue while using the key generated on other Operating system?问题 2) 在不同操作系统上使用不同版本的 OpenSSL 会导致在使用其他操作系统上生成的密钥时出现问题吗?

I am generating the Public/private Key using OpenSSL::我正在使用 OpenSSL 生成公钥/私钥::

Encrypted version加密版

To generate an encrypted version of private key, use the following command:

```openssl genrsa 2048 | openssl pkcs8 -topk8 -inform PEM -out rsa_key.p8```

To generate an encrypted version of public key, use the following command:

```openssl rsa -in rsa_key.p8 -pubout -out rsa_key.pub```

Yes, you can use it anywhere and openssl version should not be a problem.是的,你可以在任何地方使用它,openssl 版本应该没有问题。 Those keys are using standard called PKCS 8 , operating system is irrelevant.这些密钥使用称为PKCS 8 的标准,操作系统无关紧要。

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

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