How to create a pair private/public keys using Node.js crypto?

后端 未结 9 655
逝去的感伤
逝去的感伤 2020-12-23 01:59

I have to generate two keys (private and public) to encrypt a text with the public and let the user with the private key decrypt the text.

Is it possible with the mo

9条回答
  •  旧时难觅i
    2020-12-23 02:21

    You can use this rsa-json module. It just spawns a openssl process, so it is pretty dependent on the OS (it does not work by default on windows).

提交回复
热议问题