D
D
dailysse2018-12-07 17:33:33
Encryption
dailysse, 2018-12-07 17:33:33

How to create a public RSA certificate?

Good day to all. The input is 2 numbers. This is a public exponent from the server and module. All of course in the usual int. How to use them to generate a public server certificate and encrypt a message with it and transfer it to the server accordingly?
Thanks in advance for your reply

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Sumor, 2018-12-07
@Sumor

Well, if you just want to play around, then just raise your "message", which should be less than the modulo, to the power of the modulo exponent and get the ciphertext. Only encryption, in the case of using a modulus of up to 2^32, will be worse than a simple replacement with int. And you won't be able to pass messages that range from module to int.MaxInt.
There are several open source libraries for working with RSA on node.js. For example, https://github.com/rzcoder/node-rsa

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question